Lines Matching refs:Reporter
12 static void assert_count(skiatest::Reporter* reporter, const SkDeque& deq, int count) {
14 REPORTER_ASSERT(reporter, deq.empty());
15 REPORTER_ASSERT(reporter, 0 == deq.count());
16 REPORTER_ASSERT(reporter, sizeof(int) == deq.elemSize());
17 REPORTER_ASSERT(reporter, NULL == deq.front());
18 REPORTER_ASSERT(reporter, NULL == deq.back());
20 REPORTER_ASSERT(reporter, !deq.empty());
21 REPORTER_ASSERT(reporter, count == deq.count());
22 REPORTER_ASSERT(reporter, sizeof(int) == deq.elemSize());
23 REPORTER_ASSERT(reporter, NULL != deq.front());
24 REPORTER_ASSERT(reporter, NULL != deq.back());
26 REPORTER_ASSERT(reporter, deq.back() == deq.front());
28 REPORTER_ASSERT(reporter, deq.back() != deq.front());
33 static void assert_iter(skiatest::Reporter* reporter, const SkDeque& deq,
41 REPORTER_ASSERT(reporter, value == *(int*)ptr);
44 REPORTER_ASSERT(reporter, value+1 == min);
51 REPORTER_ASSERT(reporter, value == *(int*)ptr);
54 REPORTER_ASSERT(reporter, value-1 == max);
62 REPORTER_ASSERT(reporter, value == *(int*)ptr);
67 REPORTER_ASSERT(reporter, value == *(int*)ptr);
70 REPORTER_ASSERT(reporter, value-1 == max);
84 static void assert_blocks(skiatest::Reporter* reporter,
90 REPORTER_ASSERT(reporter, 1 == helper.fNumBlocksAllocated);
95 REPORTER_ASSERT(reporter,
101 static void TestSub(skiatest::Reporter* reporter, int allocCount) {
107 assert_count(reporter, deq, 0);
111 assert_count(reporter, deq, 10);
112 assert_iter(reporter, deq, 10, 1);
113 assert_blocks(reporter, deq, allocCount);
118 assert_count(reporter, deq, 5);
119 assert_iter(reporter, deq, 5, 1);
120 assert_blocks(reporter, deq, allocCount);
125 assert_count(reporter, deq, 0);
126 assert_blocks(reporter, deq, allocCount);
133 assert_count(reporter, deq, 10);
134 assert_iter(reporter, deq, 10, 1);
135 assert_blocks(reporter, deq, allocCount);
140 assert_count(reporter, deq, 5);
141 assert_iter(reporter, deq, 10, 6);
142 assert_blocks(reporter, deq, allocCount);
147 assert_count(reporter, deq, 0);
148 assert_blocks(reporter, deq, allocCount);
160 assert_count(reporter, deq, 8);
161 assert_iter(reporter, deq, 8, 1);
162 assert_blocks(reporter, deq, allocCount);
165 DEF_TEST(Deque, reporter) {
167 TestSub(reporter, 1);
169 TestSub(reporter, 10);