Lines Matching refs:ASSERT_EQ
40 ASSERT_EQ(Idmap::CanonicalIdmapPathFor("/foo", "/vendor/overlay/bar.apk"), in TEST()
49 ASSERT_EQ(header->GetMagic(), 0x504d4449U); in TEST()
50 ASSERT_EQ(header->GetVersion(), 0x01U); in TEST()
51 ASSERT_EQ(header->GetTargetCrc(), 0x1234U); in TEST()
52 ASSERT_EQ(header->GetOverlayCrc(), 0x5678U); in TEST()
53 ASSERT_EQ(header->GetTargetPath().to_string(), "target.apk"); in TEST()
54 ASSERT_EQ(header->GetOverlayPath().to_string(), "overlay.apk"); in TEST()
76 ASSERT_EQ(header->GetTargetPackageId(), 0x7fU); in TEST()
77 ASSERT_EQ(header->GetTypeCount(), 2U); in TEST()
88 ASSERT_EQ(data->GetTargetTypeId(), 0x02U); in TEST()
89 ASSERT_EQ(data->GetOverlayTypeId(), 0x02U); in TEST()
90 ASSERT_EQ(data->GetEntryCount(), 1U); in TEST()
91 ASSERT_EQ(data->GetEntryOffset(), 0U); in TEST()
92 ASSERT_EQ(data->GetEntry(0), 0U); in TEST()
103 ASSERT_EQ(data->GetHeader()->GetTargetPackageId(), 0x7fU); in TEST()
104 ASSERT_EQ(data->GetHeader()->GetTypeCount(), 2U); in TEST()
106 ASSERT_EQ(types.size(), 2U); in TEST()
108 ASSERT_EQ(types[0]->GetTargetTypeId(), 0x02U); in TEST()
109 ASSERT_EQ(types[0]->GetOverlayTypeId(), 0x02U); in TEST()
110 ASSERT_EQ(types[0]->GetEntryCount(), 1U); in TEST()
111 ASSERT_EQ(types[0]->GetEntryOffset(), 0U); in TEST()
112 ASSERT_EQ(types[0]->GetEntry(0), 0x0000U); in TEST()
114 ASSERT_EQ(types[1]->GetTargetTypeId(), 0x03U); in TEST()
115 ASSERT_EQ(types[1]->GetOverlayTypeId(), 0x03U); in TEST()
116 ASSERT_EQ(types[1]->GetEntryCount(), 3U); in TEST()
117 ASSERT_EQ(types[1]->GetEntryOffset(), 3U); in TEST()
118 ASSERT_EQ(types[1]->GetEntry(0), 0x0000U); in TEST()
119 ASSERT_EQ(types[1]->GetEntry(1), kNoEntry); in TEST()
120 ASSERT_EQ(types[1]->GetEntry(2), 0x0001U); in TEST()
132 ASSERT_EQ(idmap->GetHeader()->GetMagic(), 0x504d4449U); in TEST()
133 ASSERT_EQ(idmap->GetHeader()->GetVersion(), 0x01U); in TEST()
134 ASSERT_EQ(idmap->GetHeader()->GetTargetCrc(), 0x1234U); in TEST()
135 ASSERT_EQ(idmap->GetHeader()->GetOverlayCrc(), 0x5678U); in TEST()
136 ASSERT_EQ(idmap->GetHeader()->GetTargetPath().to_string(), "target.apk"); in TEST()
137 ASSERT_EQ(idmap->GetHeader()->GetOverlayPath().to_string(), "overlay.apk"); in TEST()
140 ASSERT_EQ(dataBlocks.size(), 1U); in TEST()
143 ASSERT_EQ(data->GetHeader()->GetTargetPackageId(), 0x7fU); in TEST()
144 ASSERT_EQ(data->GetHeader()->GetTypeCount(), 2U); in TEST()
146 ASSERT_EQ(types.size(), 2U); in TEST()
148 ASSERT_EQ(types[0]->GetTargetTypeId(), 0x02U); in TEST()
149 ASSERT_EQ(types[0]->GetOverlayTypeId(), 0x02U); in TEST()
150 ASSERT_EQ(types[0]->GetEntryCount(), 1U); in TEST()
151 ASSERT_EQ(types[0]->GetEntryOffset(), 0U); in TEST()
152 ASSERT_EQ(types[0]->GetEntry(0), 0x0000U); in TEST()
154 ASSERT_EQ(types[1]->GetTargetTypeId(), 0x03U); in TEST()
155 ASSERT_EQ(types[1]->GetOverlayTypeId(), 0x03U); in TEST()
156 ASSERT_EQ(types[1]->GetEntryCount(), 3U); in TEST()
157 ASSERT_EQ(types[1]->GetEntryOffset(), 3U); in TEST()
158 ASSERT_EQ(types[1]->GetEntry(0), 0x0000U); in TEST()
159 ASSERT_EQ(types[1]->GetEntry(1), kNoEntry); in TEST()
160 ASSERT_EQ(types[1]->GetEntry(2), 0x0001U); in TEST()
195 ASSERT_EQ(idmap->GetHeader()->GetMagic(), 0x504d4449U); in TEST()
196 ASSERT_EQ(idmap->GetHeader()->GetVersion(), 0x01U); in TEST()
197 ASSERT_EQ(idmap->GetHeader()->GetTargetCrc(), 0x76a20829); in TEST()
198 ASSERT_EQ(idmap->GetHeader()->GetOverlayCrc(), 0x8635c2ed); in TEST()
199 ASSERT_EQ(idmap->GetHeader()->GetTargetPath().to_string(), target_apk_path); in TEST()
200 ASSERT_EQ(idmap->GetHeader()->GetOverlayPath(), overlay_apk_path); in TEST()
201 ASSERT_EQ(idmap->GetHeader()->GetOverlayPath(), overlay_apk_path); in TEST()
204 ASSERT_EQ(dataBlocks.size(), 1U); in TEST()
208 ASSERT_EQ(data->GetHeader()->GetTargetPackageId(), 0x7fU); in TEST()
209 ASSERT_EQ(data->GetHeader()->GetTypeCount(), 2U); in TEST()
212 ASSERT_EQ(types.size(), 2U); in TEST()
214 ASSERT_EQ(types[0]->GetTargetTypeId(), 0x01U); in TEST()
215 ASSERT_EQ(types[0]->GetOverlayTypeId(), 0x01U); in TEST()
216 ASSERT_EQ(types[0]->GetEntryCount(), 1U); in TEST()
217 ASSERT_EQ(types[0]->GetEntryOffset(), 0U); in TEST()
218 ASSERT_EQ(types[0]->GetEntry(0), 0x0000U); in TEST()
220 ASSERT_EQ(types[1]->GetTargetTypeId(), 0x02U); in TEST()
221 ASSERT_EQ(types[1]->GetOverlayTypeId(), 0x02U); in TEST()
222 ASSERT_EQ(types[1]->GetEntryCount(), 4U); in TEST()
223 ASSERT_EQ(types[1]->GetEntryOffset(), 12U); in TEST()
224 ASSERT_EQ(types[1]->GetEntry(0), 0x0000U); in TEST()
225 ASSERT_EQ(types[1]->GetEntry(1), kNoEntry); in TEST()
226 ASSERT_EQ(types[1]->GetEntry(2), 0x0001U); in TEST()
227 ASSERT_EQ(types[1]->GetEntry(3), 0x0002U); in TEST()
241 ASSERT_EQ(dataBlocks.size(), 1U); in TEST()
245 ASSERT_EQ(data->GetHeader()->GetTargetPackageId(), 0x7fU); in TEST()
246 ASSERT_EQ(data->GetHeader()->GetTypeCount(), 1U); in TEST()
249 ASSERT_EQ(types.size(), 1U); in TEST()
251 ASSERT_EQ(types[0]->GetTargetTypeId(), 0x02U); in TEST()
252 ASSERT_EQ(types[0]->GetOverlayTypeId(), 0x01U); in TEST()
253 ASSERT_EQ(types[0]->GetEntryCount(), 4U); in TEST()
254 ASSERT_EQ(types[0]->GetEntryOffset(), 8U); in TEST()
255 ASSERT_EQ(types[0]->GetEntry(0), 0x0000U); // string/policy_public in TEST()
256 ASSERT_EQ(types[0]->GetEntry(1), kNoEntry); // string/policy_signature in TEST()
257 ASSERT_EQ(types[0]->GetEntry(2), 0x0001U); // string/policy_system in TEST()
258 ASSERT_EQ(types[0]->GetEntry(3), 0x0002U); // string/policy_system_vendor in TEST()
271 ASSERT_EQ(dataBlocks.size(), 1U); in TEST()
275 ASSERT_EQ(data->GetHeader()->GetTargetPackageId(), 0x7fU); in TEST()
276 ASSERT_EQ(data->GetHeader()->GetTypeCount(), 1U); in TEST()
279 ASSERT_EQ(types.size(), 1U); in TEST()
281 ASSERT_EQ(types[0]->GetTargetTypeId(), 0x02U); in TEST()
282 ASSERT_EQ(types[0]->GetOverlayTypeId(), 0x01U); in TEST()
283 ASSERT_EQ(types[0]->GetEntryCount(), 1U); in TEST()
284 ASSERT_EQ(types[0]->GetEntryOffset(), 9U); in TEST()
285 ASSERT_EQ(types[0]->GetEntry(0), 0x0000U); // string/policy_signature in TEST()
300 ASSERT_EQ(dataBlocks.size(), 1U); in TEST()
304 ASSERT_EQ(data->GetHeader()->GetTargetPackageId(), 0x7fU); in TEST()
305 ASSERT_EQ(data->GetHeader()->GetTypeCount(), 1U); in TEST()
308 ASSERT_EQ(types.size(), 1U); in TEST()
310 ASSERT_EQ(types[0]->GetTargetTypeId(), 0x02U); in TEST()
311 ASSERT_EQ(types[0]->GetOverlayTypeId(), 0x01U); in TEST()
312 ASSERT_EQ(types[0]->GetEntryCount(), 4U); in TEST()
313 ASSERT_EQ(types[0]->GetEntryOffset(), 8U); in TEST()
314 ASSERT_EQ(types[0]->GetEntry(0), 0x0005U); // string/policy_public in TEST()
315 ASSERT_EQ(types[0]->GetEntry(1), kNoEntry); // string/policy_signature in TEST()
316 ASSERT_EQ(types[0]->GetEntry(2), 0x0007U); // string/policy_system in TEST()
317 ASSERT_EQ(types[0]->GetEntry(3), 0x0008U); // string/policy_system_vendor in TEST()
332 ASSERT_EQ(dataBlocks.size(), 1U); in TEST()
336 ASSERT_EQ(data->GetHeader()->GetTargetPackageId(), 0x7fU); in TEST()
337 ASSERT_EQ(data->GetHeader()->GetTypeCount(), 1U); in TEST()
340 ASSERT_EQ(types.size(), 1U); in TEST()
342 ASSERT_EQ(types[0]->GetTargetTypeId(), 0x02U); in TEST()
343 ASSERT_EQ(types[0]->GetOverlayTypeId(), 0x01U); in TEST()
344 ASSERT_EQ(types[0]->GetEntryCount(), 9U); in TEST()
345 ASSERT_EQ(types[0]->GetEntryOffset(), 3U); in TEST()
346 ASSERT_EQ(types[0]->GetEntry(0), 0x0000U); // string/not_overlayable in TEST()
347 ASSERT_EQ(types[0]->GetEntry(1), 0x0001U); // string/policy_odm in TEST()
348 ASSERT_EQ(types[0]->GetEntry(2), 0x0002U); // string/policy_oem in TEST()
349 ASSERT_EQ(types[0]->GetEntry(3), 0x0003U); // string/other in TEST()
350 ASSERT_EQ(types[0]->GetEntry(4), 0x0004U); // string/policy_product in TEST()
351 ASSERT_EQ(types[0]->GetEntry(5), 0x0005U); // string/policy_public in TEST()
352 ASSERT_EQ(types[0]->GetEntry(6), 0x0006U); // string/policy_signature in TEST()
353 ASSERT_EQ(types[0]->GetEntry(7), 0x0007U); // string/policy_system in TEST()
354 ASSERT_EQ(types[0]->GetEntry(8), 0x0008U); // string/policy_system_vendor in TEST()
367 ASSERT_EQ(dataBlocks.size(), 1U); in TEST()
371 ASSERT_EQ(data->GetHeader()->GetTargetPackageId(), 0x7fU); in TEST()
372 ASSERT_EQ(data->GetHeader()->GetTypeCount(), 2U); in TEST()
375 ASSERT_EQ(types.size(), 2U); in TEST()
377 ASSERT_EQ(types[0]->GetTargetTypeId(), 0x01U); in TEST()
378 ASSERT_EQ(types[0]->GetOverlayTypeId(), 0x01U); in TEST()
379 ASSERT_EQ(types[0]->GetEntryCount(), 1U); in TEST()
380 ASSERT_EQ(types[0]->GetEntryOffset(), 0U); in TEST()
381 ASSERT_EQ(types[0]->GetEntry(0), 0x0000U); // string/int1 in TEST()
383 ASSERT_EQ(types[1]->GetTargetTypeId(), 0x02U); in TEST()
384 ASSERT_EQ(types[1]->GetOverlayTypeId(), 0x02U); in TEST()
385 ASSERT_EQ(types[1]->GetEntryCount(), 4U); in TEST()
386 ASSERT_EQ(types[1]->GetEntryOffset(), 12U); in TEST()
387 ASSERT_EQ(types[1]->GetEntry(0), 0x0000U); // string/str1 in TEST()
388 ASSERT_EQ(types[1]->GetEntry(1), kNoEntry); // string/str2 in TEST()
389 ASSERT_EQ(types[1]->GetEntry(2), 0x0001U); // string/str3 in TEST()
390 ASSERT_EQ(types[1]->GetEntry(3), 0x0002U); // string/str4 in TEST()
414 ASSERT_EQ(dataBlocks.size(), 1U); in TEST()
417 ASSERT_EQ(data->GetHeader()->GetTargetPackageId(), 0x7fU); in TEST()
418 ASSERT_EQ(data->GetHeader()->GetTypeCount(), 1U); in TEST()
421 ASSERT_EQ(types.size(), 1U); in TEST()
423 ASSERT_EQ(types[0]->GetTargetTypeId(), 0x02U); in TEST()
424 ASSERT_EQ(types[0]->GetOverlayTypeId(), 0x01U); in TEST()
425 ASSERT_EQ(types[0]->GetEntryCount(), 9U); in TEST()
426 ASSERT_EQ(types[0]->GetEntryOffset(), 3U); in TEST()
427 ASSERT_EQ(types[0]->GetEntry(0), 0x0000U); // string/not_overlayable in TEST()
428 ASSERT_EQ(types[0]->GetEntry(1), 0x0001U); // string/policy_odm in TEST()
429 ASSERT_EQ(types[0]->GetEntry(2), 0x0002U); // string/policy_oem in TEST()
430 ASSERT_EQ(types[0]->GetEntry(3), 0x0003U); // string/other in TEST()
431 ASSERT_EQ(types[0]->GetEntry(4), 0x0004U); // string/policy_product in TEST()
432 ASSERT_EQ(types[0]->GetEntry(5), 0x0005U); // string/policy_public in TEST()
433 ASSERT_EQ(types[0]->GetEntry(6), 0x0006U); // string/policy_signature in TEST()
434 ASSERT_EQ(types[0]->GetEntry(7), 0x0007U); // string/policy_system in TEST()
435 ASSERT_EQ(types[0]->GetEntry(8), 0x0008U); // string/policy_system_vendor in TEST()
627 ASSERT_EQ(test_stream.str(), in TEST()