Add/resurrect support for bundles of WebStore items.
[chromium-blink-merge.git] / tools / binary_size / explain_binary_size_delta_unittest.py
blobd818d83f24c40fb59c537a124308aaaf0334e8f7
1 #!/usr/bin/env python
2 # Copyright 2014 The Chromium Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file.
6 """Check that explain_binary_size_delta seems to work."""
8 import cStringIO
9 import sys
10 import unittest
12 import explain_binary_size_delta
15 class ExplainBinarySizeDeltaTest(unittest.TestCase):
17 def testCompare(self):
18 # List entries have form:
19 # symbol_name, symbol_type, symbol_size, file_path, memory_address
20 symbol_list1 = (
21 # File with one symbol, left as-is.
22 ( 'unchanged', 't', 1000, '/file_unchanged', 0x1 ),
23 # File with one symbol, changed.
24 ( 'changed', 't', 1000, '/file_all_changed', 0x2 ),
25 # File with one symbol, deleted.
26 ( 'removed', 't', 1000, '/file_all_deleted', 0x3 ),
27 # File with two symbols, one unchanged, one changed, same bucket
28 ( 'unchanged', 't', 1000, '/file_pair_unchanged_changed', 0x4 ),
29 ( 'changed', 't', 1000, '/file_pair_unchanged_changed', 0x5 ),
30 # File with two symbols, one unchanged, one deleted, same bucket
31 ( 'unchanged', 't', 1000, '/file_pair_unchanged_removed', 0x6 ),
32 ( 'removed', 't', 1000, '/file_pair_unchanged_removed', 0x7 ),
33 # File with two symbols, one unchanged, one added, same bucket
34 ( 'unchanged', 't', 1000, '/file_pair_unchanged_added', 0x8 ),
35 # File with two symbols, one unchanged, one changed, different bucket
36 ( 'unchanged', 't', 1000, '/file_pair_unchanged_diffbuck_changed', 0x9 ),
37 ( 'changed', '@', 1000, '/file_pair_unchanged_diffbuck_changed', 0xa ),
38 # File with two symbols, one unchanged, one deleted, different bucket
39 ( 'unchanged', 't', 1000, '/file_pair_unchanged_diffbuck_removed', 0xb ),
40 ( 'removed', '@', 1000, '/file_pair_unchanged_diffbuck_removed', 0xc ),
41 # File with two symbols, one unchanged, one added, different bucket
42 ( 'unchanged', 't', 1000, '/file_pair_unchanged_diffbuck_added', 0xd ),
43 # File with four symbols, one added, one removed,
44 # one changed, one unchanged
45 ( 'size_changed', 't', 1000, '/file_tetra', 0xe ),
46 ( 'removed', 't', 1000, '/file_tetra', 0xf ),
47 ( 'unchanged', 't', 1000, '/file_tetra', 0x10 ),
50 symbol_list2 = (
51 # File with one symbol, left as-is.
52 ( 'unchanged', 't', 1000, '/file_unchanged', 0x1 ),
53 # File with one symbol, changed.
54 ( 'changed', 't', 2000, '/file_all_changed', 0x2 ),
55 # File with two symbols, one unchanged, one changed, same bucket
56 ( 'unchanged', 't', 1000, '/file_pair_unchanged_changed', 0x3 ),
57 ( 'changed', 't', 2000, '/file_pair_unchanged_changed', 0x4 ),
58 # File with two symbols, one unchanged, one deleted, same bucket
59 ( 'unchanged', 't', 1000, '/file_pair_unchanged_removed', 0x5 ),
60 # File with two symbols, one unchanged, one added, same bucket
61 ( 'unchanged', 't', 1000, '/file_pair_unchanged_added', 0x6 ),
62 ( 'added', 't', 1000, '/file_pair_unchanged_added', 0x7 ),
63 # File with two symbols, one unchanged, one changed, different bucket
64 ( 'unchanged', 't', 1000, '/file_pair_unchanged_diffbuck_changed', 0x8 ),
65 ( 'changed', '@', 2000, '/file_pair_unchanged_diffbuck_changed', 0x9 ),
66 # File with two symbols, one unchanged, one deleted, different bucket
67 ( 'unchanged', 't', 1000, '/file_pair_unchanged_diffbuck_removed', 0xa ),
68 # File with two symbols, one unchanged, one added, different bucket
69 ( 'unchanged', 't', 1000, '/file_pair_unchanged_diffbuck_added', 0xb ),
70 ( 'added', '@', 1000, '/file_pair_unchanged_diffbuck_added', 0xc ),
71 # File with four symbols, one added, one removed,
72 # one changed, one unchanged
73 ( 'size_changed', 't', 2000, '/file_tetra', 0xd ),
74 ( 'unchanged', 't', 1000, '/file_tetra', 0xe ),
75 ( 'added', 't', 1000, '/file_tetra', 0xf ),
76 # New file with one symbol added
77 ( 'added', 't', 1000, '/file_new', 0x10 ),
80 # Here we go
81 (added, removed, changed, unchanged) = \
82 explain_binary_size_delta.Compare(symbol_list1, symbol_list2)
84 def delta(file_path, symbol_type, symbol_name, old_size, new_size):
85 delta_info = explain_binary_size_delta.DeltaInfo(
86 file_path, symbol_type, symbol_name, False)
87 delta_info.old_size = old_size
88 delta_info.new_size = new_size
89 return delta_info
91 # File with one symbol, left as-is.
92 assert delta('/file_unchanged', 't', 'unchanged', 1000, 1000) in unchanged
93 # File with one symbol, changed.
94 assert delta('/file_all_changed', 't', 'changed', 1000, 2000) in changed
95 # File with one symbol, deleted.
96 assert delta('/file_all_deleted', 't', 'removed', 1000, None) in removed
97 # New file with one symbol added
98 assert delta('/file_new', 't', 'added', None, 1000) in added
99 # File with two symbols, one unchanged, one changed, same bucket
100 assert delta('/file_pair_unchanged_changed',
101 't', 'unchanged', 1000, 1000) in unchanged
102 assert delta('/file_pair_unchanged_changed',
103 't', 'changed', 1000, 2000) in changed
104 # File with two symbols, one unchanged, one removed, same bucket
105 assert delta('/file_pair_unchanged_removed',
106 't', 'unchanged', 1000, 1000) in unchanged
107 assert delta('/file_pair_unchanged_removed',
108 't', 'removed', 1000, None) in removed
109 # File with two symbols, one unchanged, one added, same bucket
110 assert delta('/file_pair_unchanged_added',
111 't', 'unchanged', 1000, 1000) in unchanged
112 assert delta('/file_pair_unchanged_added',
113 't', 'added', None, 1000) in added
114 # File with two symbols, one unchanged, one changed, different bucket
115 assert delta('/file_pair_unchanged_diffbuck_changed',
116 't', 'unchanged', 1000, 1000) in unchanged
117 assert delta('/file_pair_unchanged_diffbuck_changed',
118 '@', 'changed', 1000, 2000) in changed
119 # File with two symbols, one unchanged, one removed, different bucket
120 assert delta('/file_pair_unchanged_diffbuck_removed',
121 't', 'unchanged', 1000, 1000) in unchanged
122 assert delta('/file_pair_unchanged_diffbuck_removed',
123 '@', 'removed', 1000, None) in removed
124 # File with two symbols, one unchanged, one added, different bucket
125 assert delta('/file_pair_unchanged_diffbuck_added',
126 't', 'unchanged', 1000, 1000) in unchanged
127 assert delta('/file_pair_unchanged_diffbuck_added',
128 '@', 'added', None, 1000) in added
129 # File with four symbols, one added, one removed, one changed, one unchanged
130 assert delta('/file_tetra', 't', 'size_changed', 1000, 2000) in changed
131 assert delta('/file_tetra', 't', 'unchanged', 1000, 1000) in unchanged
132 assert delta('/file_tetra', 't', 'added', None, 1000) in added
133 assert delta('/file_tetra', 't', 'removed', 1000, None) in removed
135 # Now check final stats.
136 orig_stdout = sys.stdout
137 output_collector = cStringIO.StringIO()
138 sys.stdout = output_collector
139 try:
140 explain_binary_size_delta.CrunchStats(added, removed, changed,
141 unchanged, True, True)
142 finally:
143 sys.stdout = orig_stdout
144 result = output_collector.getvalue()
146 expected_output = """\
147 Total change: +4000 bytes
148 =========================
149 4 added, totalling +4000 bytes across 4 sources
150 4 removed, totalling -4000 bytes across 4 sources
151 4 grown, for a net change of +4000 bytes \
152 (4000 bytes before, 8000 bytes after) across 4 sources
153 8 unchanged, totalling 8000 bytes
154 Source stats:
155 11 sources encountered.
156 1 completely new.
157 1 removed completely.
158 8 partially changed.
159 1 completely unchanged.
160 Per-source Analysis:
162 --------------------------------------------------
163 +1000 - Source: /file_new - (gained 1000, lost 0)
164 --------------------------------------------------
165 New symbols:
166 +1000: added type=t, size=1000 bytes
168 ---------------------------------------------------------------------
169 +1000 - Source: /file_pair_unchanged_changed - (gained 1000, lost 0)
170 ---------------------------------------------------------------------
171 Grown symbols:
172 +1000: changed type=t, (was 1000 bytes, now 2000 bytes)
174 ----------------------------------------------------------------------------
175 +1000 - Source: /file_pair_unchanged_diffbuck_added - (gained 1000, lost 0)
176 ----------------------------------------------------------------------------
177 New symbols:
178 +1000: added type=@, size=1000 bytes
180 -------------------------------------------------------------------
181 +1000 - Source: /file_pair_unchanged_added - (gained 1000, lost 0)
182 -------------------------------------------------------------------
183 New symbols:
184 +1000: added type=t, size=1000 bytes
186 ------------------------------------------------------------------------------
187 +1000 - Source: /file_pair_unchanged_diffbuck_changed - (gained 1000, lost 0)
188 ------------------------------------------------------------------------------
189 Grown symbols:
190 +1000: changed type=@, (was 1000 bytes, now 2000 bytes)
192 ----------------------------------------------------------
193 +1000 - Source: /file_all_changed - (gained 1000, lost 0)
194 ----------------------------------------------------------
195 Grown symbols:
196 +1000: changed type=t, (was 1000 bytes, now 2000 bytes)
198 -------------------------------------------------------
199 +1000 - Source: /file_tetra - (gained 2000, lost 1000)
200 -------------------------------------------------------
201 New symbols:
202 +1000: added type=t, size=1000 bytes
203 Removed symbols:
204 -1000: removed type=t, size=1000 bytes
205 Grown symbols:
206 +1000: size_changed type=t, (was 1000 bytes, now 2000 bytes)
208 ------------------------------------------------------------------------------
209 -1000 - Source: /file_pair_unchanged_diffbuck_removed - (gained 0, lost 1000)
210 ------------------------------------------------------------------------------
211 Removed symbols:
212 -1000: removed type=@, size=1000 bytes
214 ----------------------------------------------------------
215 -1000 - Source: /file_all_deleted - (gained 0, lost 1000)
216 ----------------------------------------------------------
217 Removed symbols:
218 -1000: removed type=t, size=1000 bytes
220 ---------------------------------------------------------------------
221 -1000 - Source: /file_pair_unchanged_removed - (gained 0, lost 1000)
222 ---------------------------------------------------------------------
223 Removed symbols:
224 -1000: removed type=t, size=1000 bytes
227 self.maxDiff = None
228 self.assertMultiLineEqual(expected_output, result)
231 def testCompareStringEntries(self):
232 # List entries have form:
233 # symbol_name, symbol_type, symbol_size, file_path, memory_address
234 symbol_list1 = (
235 # File with one string.
236 ( '.L.str107', 'r', 8, '/file_with_strs', 0x1 ),
239 symbol_list2 = (
240 # Two files with one string each, same name.
241 ( '.L.str107', 'r', 8, '/file_with_strs', 0x1 ),
242 ( '.L.str107', 'r', 7, '/other_file_with_strs', 0x2 ),
245 # Here we go
246 (added, removed, changed, unchanged) = \
247 explain_binary_size_delta.Compare(symbol_list1, symbol_list2)
250 # Now check final stats.
251 orig_stdout = sys.stdout
252 output_collector = cStringIO.StringIO()
253 sys.stdout = output_collector
254 try:
255 explain_binary_size_delta.CrunchStats(added, removed, changed,
256 unchanged, True, True)
257 finally:
258 sys.stdout = orig_stdout
259 result = output_collector.getvalue()
261 expected_output = """\
262 Total change: +7 bytes
263 ======================
264 1 added, totalling +7 bytes across 1 sources
265 1 unchanged, totalling 8 bytes
266 Source stats:
267 2 sources encountered.
268 1 completely new.
269 0 removed completely.
270 0 partially changed.
271 1 completely unchanged.
272 Per-source Analysis:
274 --------------------------------------------------------
275 +7 - Source: /other_file_with_strs - (gained 7, lost 0)
276 --------------------------------------------------------
277 New symbols:
278 +7: .L.str107 type=r, size=7 bytes
281 self.maxDiff = None
282 self.assertMultiLineEqual(expected_output, result)
284 def testCompareStringEntriesWithNoFile(self):
285 # List entries have form:
286 # symbol_name, symbol_type, symbol_size, file_path, memory_address
287 symbol_list1 = (
288 ( '.L.str104', 'r', 21, '??', 0x1 ), # Will change size.
289 ( '.L.str105', 'r', 17, '??', 0x2 ), # Same.
290 ( '.L.str106', 'r', 13, '??', 0x3 ), # Will be removed.
291 ( '.L.str106', 'r', 3, '??', 0x4 ), # Same.
292 ( '.L.str106', 'r', 3, '??', 0x5 ), # Will be removed.
293 ( '.L.str107', 'r', 8, '??', 0x6 ), # Will be removed (other sizes).
296 symbol_list2 = (
297 # Two files with one string each, same name.
298 ( '.L.str104', 'r', 19, '??', 0x1 ), # Changed.
299 ( '.L.str105', 'r', 11, '??', 0x2 ), # New size for multi-symbol.
300 ( '.L.str105', 'r', 17, '??', 0x3 ), # New of same size for multi-symbol.
301 ( '.L.str105', 'r', 17, '??', 0x4 ), # Same.
302 ( '.L.str106', 'r', 3, '??', 0x5 ), # Same.
303 ( '.L.str107', 'r', 5, '??', 0x6 ), # New size for symbol.
304 ( '.L.str107', 'r', 7, '??', 0x7 ), # New size for symbol.
305 ( '.L.str108', 'r', 8, '??', 0x8 ), # New symbol.
308 # Here we go
309 (added, removed, changed, unchanged) = \
310 explain_binary_size_delta.Compare(symbol_list1, symbol_list2)
313 # Now check final stats.
314 orig_stdout = sys.stdout
315 output_collector = cStringIO.StringIO()
316 sys.stdout = output_collector
317 try:
318 explain_binary_size_delta.CrunchStats(added, removed, changed,
319 unchanged, True, True)
320 finally:
321 sys.stdout = orig_stdout
322 result = output_collector.getvalue()
324 expected_output = """\
325 Total change: +22 bytes
326 =======================
327 5 added, totalling +48 bytes across 1 sources
328 3 removed, totalling -24 bytes across 1 sources
329 1 shrunk, for a net change of -2 bytes (21 bytes before, 19 bytes after) \
330 across 1 sources
331 2 unchanged, totalling 20 bytes
332 Source stats:
333 1 sources encountered.
334 0 completely new.
335 0 removed completely.
336 1 partially changed.
337 0 completely unchanged.
338 Per-source Analysis:
340 ----------------------------------------
341 +22 - Source: ?? - (gained 48, lost 26)
342 ----------------------------------------
343 New symbols:
344 +17: .L.str105 type=r, size=17 bytes
345 +11: .L.str105 type=r, size=11 bytes
346 +8: .L.str108 type=r, size=8 bytes
347 +7: .L.str107 type=r, size=7 bytes
348 +5: .L.str107 type=r, size=5 bytes
349 Removed symbols:
350 -3: .L.str106 type=r, size=3 bytes
351 -8: .L.str107 type=r, size=8 bytes
352 -13: .L.str106 type=r, size=13 bytes
353 Shrunk symbols:
354 -2: .L.str104 type=r, (was 21 bytes, now 19 bytes)
357 self.maxDiff = None
358 self.assertMultiLineEqual(expected_output, result)
360 def testCompareSharedSpace(self):
361 # List entries have form:
362 # symbol_name, symbol_type, symbol_size, file_path, memory_address
363 symbol_list1 = (
364 # File with two symbols, same address.
365 ( 'sym1', 'r', 8, '/file', 0x1 ),
366 ( 'sym2', 'r', 8, '/file', 0x1 ),
369 symbol_list2 = (
370 # File with two symbols, same address.
371 ( 'sym1', 'r', 4, '/file', 0x1 ),
372 ( 'sym2', 'r', 4, '/file', 0x1 ),
375 # Here we go
376 (added, removed, changed, unchanged) = \
377 explain_binary_size_delta.Compare(symbol_list1, symbol_list2)
380 # Now check final stats.
381 orig_stdout = sys.stdout
382 output_collector = cStringIO.StringIO()
383 sys.stdout = output_collector
384 try:
385 explain_binary_size_delta.CrunchStats(added, removed, changed,
386 unchanged, True, True)
387 finally:
388 sys.stdout = orig_stdout
389 result = output_collector.getvalue()
391 expected_output = """\
392 Total change: -4 bytes
393 ======================
394 2 shrunk, for a net change of -4 bytes (8 bytes before, 4 bytes after) \
395 across 1 sources
396 0 unchanged, totalling 0 bytes
397 Source stats:
398 1 sources encountered.
399 0 completely new.
400 0 removed completely.
401 1 partially changed.
402 0 completely unchanged.
403 Per-source Analysis:
405 ----------------------------------------
406 -4 - Source: /file - (gained 0, lost 4)
407 ----------------------------------------
408 Shrunk symbols:
409 -2: sym1 type=r, (was 4 bytes, now 2 bytes) (adjusted sizes because \
410 of memory sharing)
411 -2: sym2 type=r, (was 4 bytes, now 2 bytes) (adjusted sizes because \
412 of memory sharing)
415 self.maxDiff = None
416 self.assertMultiLineEqual(expected_output, result)
419 def testCompareSharedSpaceDuplicateSymbols(self):
420 # List entries have form:
421 # symbol_name, symbol_type, symbol_size, file_path, memory_address
422 symbol_list1 = (
423 # File with two symbols, same address.
424 ( 'sym1', 'r', 7, '/file', 0x2 ),
425 ( 'sym1', 'r', 8, '/file', 0x1 ),
426 ( 'sym2', 'r', 8, '/file', 0x1 ),
429 symbol_list2 = (
430 # File with two symbols, same address.
431 ( 'sym1', 'r', 7, '/file', 0x2 ),
432 ( 'sym1', 'r', 4, '/file', 0x1 ),
433 ( 'sym2', 'r', 4, '/file', 0x1 ),
436 # Here we go
437 (added, removed, changed, unchanged) = \
438 explain_binary_size_delta.Compare(symbol_list1, symbol_list2)
441 # Now check final stats.
442 orig_stdout = sys.stdout
443 output_collector = cStringIO.StringIO()
444 sys.stdout = output_collector
445 try:
446 explain_binary_size_delta.CrunchStats(added, removed, changed,
447 unchanged, True, True)
448 finally:
449 sys.stdout = orig_stdout
450 result = output_collector.getvalue()
452 expected_output = """\
453 Total change: -4 bytes
454 ======================
455 1 added, totalling +2 bytes across 1 sources
456 1 removed, totalling -4 bytes across 1 sources
457 1 shrunk, for a net change of -2 bytes (4 bytes before, 2 bytes after) \
458 across 1 sources
459 1 unchanged, totalling 7 bytes
460 Source stats:
461 1 sources encountered.
462 0 completely new.
463 0 removed completely.
464 1 partially changed.
465 0 completely unchanged.
466 Per-source Analysis:
468 ----------------------------------------
469 -4 - Source: /file - (gained 2, lost 6)
470 ----------------------------------------
471 New symbols:
472 +2: sym1 type=r, size=2 bytes (adjusted sizes because of memory \
473 sharing)
474 Removed symbols:
475 -4: sym1 type=r, size=4 bytes (adjusted sizes because of memory \
476 sharing)
477 Shrunk symbols:
478 -2: sym2 type=r, (was 4 bytes, now 2 bytes) (adjusted sizes because \
479 of memory sharing)
482 self.maxDiff = None
483 self.assertMultiLineEqual(expected_output, result)
485 def testCompareSharedSpaceBecomingUnshared(self):
486 # List entries have form:
487 # symbol_name, symbol_type, symbol_size, file_path, memory_address
488 symbol_list1 = (
489 # File with two symbols, same address.
490 ( 'sym1', 'r', 8, '/file', 0x1 ),
491 ( 'sym2', 'r', 8, '/file', 0x1 ),
494 symbol_list2 = (
495 # File with two symbols, not the same address.
496 ( 'sym1', 'r', 8, '/file', 0x1 ),
497 ( 'sym2', 'r', 6, '/file', 0x2 ),
500 # Here we go
501 (added, removed, changed, unchanged) = \
502 explain_binary_size_delta.Compare(symbol_list1, symbol_list2)
505 # Now check final stats.
506 orig_stdout = sys.stdout
507 output_collector = cStringIO.StringIO()
508 sys.stdout = output_collector
509 try:
510 explain_binary_size_delta.CrunchStats(added, removed, changed,
511 unchanged, True, True)
512 finally:
513 sys.stdout = orig_stdout
514 result = output_collector.getvalue()
516 expected_output = """\
517 Total change: +6 bytes
518 ======================
519 2 grown, for a net change of +6 bytes (8 bytes before, 14 bytes after) \
520 across 1 sources
521 0 unchanged, totalling 0 bytes
522 Source stats:
523 1 sources encountered.
524 0 completely new.
525 0 removed completely.
526 1 partially changed.
527 0 completely unchanged.
528 Per-source Analysis:
530 ----------------------------------------
531 +6 - Source: /file - (gained 6, lost 0)
532 ----------------------------------------
533 Grown symbols:
534 +4: sym1 type=r, (was 4 bytes, now 8 bytes) (adjusted sizes because \
535 of memory sharing)
536 +2: sym2 type=r, (was 4 bytes, now 6 bytes) (adjusted sizes because \
537 of memory sharing)
540 self.maxDiff = None
541 self.assertMultiLineEqual(expected_output, result)
543 def testCompareSymbolsBecomingUnshared(self):
544 # List entries have form:
545 # symbol_name, symbol_type, symbol_size, file_path, memory_address
546 symbol_list1 = (
547 # File with two symbols, not the same address.
548 ( 'sym1', 'r', 8, '/file', 0x1 ),
549 ( 'sym2', 'r', 6, '/file', 0x2 ),
552 symbol_list2 = (
553 # File with two symbols, same address.
554 ( 'sym1', 'r', 8, '/file', 0x1 ),
555 ( 'sym2', 'r', 8, '/file', 0x1 ),
558 # Here we go
559 (added, removed, changed, unchanged) = \
560 explain_binary_size_delta.Compare(symbol_list1, symbol_list2)
563 # Now check final stats.
564 orig_stdout = sys.stdout
565 output_collector = cStringIO.StringIO()
566 sys.stdout = output_collector
567 try:
568 explain_binary_size_delta.CrunchStats(added, removed, changed,
569 unchanged, True, True)
570 finally:
571 sys.stdout = orig_stdout
572 result = output_collector.getvalue()
574 expected_output = """\
575 Total change: -6 bytes
576 ======================
577 2 shrunk, for a net change of -6 bytes (14 bytes before, 8 bytes after) \
578 across 1 sources
579 0 unchanged, totalling 0 bytes
580 Source stats:
581 1 sources encountered.
582 0 completely new.
583 0 removed completely.
584 1 partially changed.
585 0 completely unchanged.
586 Per-source Analysis:
588 ----------------------------------------
589 -6 - Source: /file - (gained 0, lost 6)
590 ----------------------------------------
591 Shrunk symbols:
592 -2: sym2 type=r, (was 6 bytes, now 4 bytes) (adjusted sizes because \
593 of memory sharing)
594 -4: sym1 type=r, (was 8 bytes, now 4 bytes) (adjusted sizes because \
595 of memory sharing)
598 self.maxDiff = None
599 self.assertMultiLineEqual(expected_output, result)
601 def testDeltaInfo(self):
602 x = explain_binary_size_delta.DeltaInfo("path", "t", "sym_name", False)
603 assert x == x
604 y = explain_binary_size_delta.DeltaInfo("path", "t", "sym_name", False)
605 assert x == y
607 y.new_size = 12
608 assert x != y
610 x.new_size = 12
611 assert x == y
613 z = explain_binary_size_delta.DeltaInfo("path", "t", "sym_name", True)
614 assert not (x == z)
615 assert x != z
617 w = explain_binary_size_delta.DeltaInfo("other_path", "t", "sym_name", True)
618 assert w != z
620 if __name__ == '__main__':
621 unittest.main()