14template <
class GrowableArrayInt,
class GrowableArrayInt64>
17 EXPECT_EQ(0, g.length());
21 EXPECT_EQ(1, g.length());
24 const GrowableArrayInt& temp = g;
25 EXPECT_EQ(5, temp[0]);
26 EXPECT_EQ(3, temp[1]);
27 for (
int i = 0;
i < 10000;
i++) {
30 EXPECT_EQ(10002, g.length());
31 EXPECT_EQ(10000 - 1, g.Last());
33 GrowableArrayInt64
f(10);
34 EXPECT_EQ(0,
f.length());
37 EXPECT_EQ(2,
f.length());
38 for (int64_t l = 0; l < 100; l++) {
41 EXPECT_EQ(102,
f.length());
42 EXPECT_EQ(100 - 1,
f.Last());
43 EXPECT_EQ(-1LL,
f[0]);
46 EXPECT_EQ(0,
h.length());
50 EXPECT_EQ(3,
h.length());
51 EXPECT_EQ(103,
h.Last());
53 EXPECT_EQ(2,
h.length());
54 EXPECT_EQ(102,
h.Last());
56 EXPECT_EQ(1,
h.length());
57 EXPECT_EQ(101,
h.Last());
59 EXPECT_EQ(0,
h.length());
94 EXPECT_EQ(4, g.
Last());
100 EXPECT_EQ(0,
test1.length());
101 test1.Add(Symbols::Int());
103 EXPECT_EQ(1,
test1.length());
107 test2->
Add(Symbols::GetterPrefix());
108 EXPECT((*test2)[0].ptr() == Symbols::GetterPrefix().ptr());
109 EXPECT_EQ(1, test2->
length());
116 int* a_data =
a.data();
120 EXPECT_EQ(0,
a.length());
121 EXPECT_EQ((
int*)
nullptr,
a.data());
122 EXPECT_EQ(2,
b.length());
123 EXPECT_EQ(a_data,
b.data());
132 int* a_data =
a.data();
133 int* b_data =
b.data();
137 EXPECT_EQ(1,
a.length());
138 EXPECT_EQ(b_data,
a.data());
139 EXPECT_EQ(3,
b.length());
140 EXPECT_EQ(a_data,
b.data());
static void test1(skiatest::Reporter *reporter, SkWriter32 *writer)
void Sort(int compare(const T *, const T *))
static Thread * Current()
static int greatestFirst(const int *a, const int *b)
ISOLATE_UNIT_TEST_CASE(StackAllocatedDestruction)
TEST_CASE(DirectoryCurrent)