OLD | NEW |
1 #!/usr/bin/python | 1 #!/usr/bin/python |
2 # Copyright (c) 2016 The WebRTC project authors. All Rights Reserved. | 2 # Copyright (c) 2016 The WebRTC project authors. All Rights Reserved. |
3 # | 3 # |
4 # Use of this source code is governed by a BSD-style license | 4 # Use of this source code is governed by a BSD-style license |
5 # that can be found in the LICENSE file in the root of the source | 5 # that can be found in the LICENSE file in the root of the source |
6 # tree. An additional intellectual property rights grant can be found | 6 # tree. An additional intellectual property rights grant can be found |
7 # in the file PATENTS. All contributing project authors may | 7 # in the file PATENTS. All contributing project authors may |
8 # be found in the AUTHORS file in the root of the source tree. | 8 # be found in the AUTHORS file in the root of the source tree. |
9 | 9 |
10 """Tests for mb.py.""" | 10 """Tests for mb.py.""" |
(...skipping 424 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
435 files=test_files, ret=0) | 435 files=test_files, ret=0) |
436 | 436 |
437 isolate_file = mbw.files['/fake_src/out/Default/base_unittests.isolate'] | 437 isolate_file = mbw.files['/fake_src/out/Default/base_unittests.isolate'] |
438 isolate_file_contents = ast.literal_eval(isolate_file) | 438 isolate_file_contents = ast.literal_eval(isolate_file) |
439 files = isolate_file_contents['variables']['files'] | 439 files = isolate_file_contents['variables']['files'] |
440 command = isolate_file_contents['variables']['command'] | 440 command = isolate_file_contents['variables']['command'] |
441 | 441 |
442 self.assertEqual(files, [ | 442 self.assertEqual(files, [ |
443 '../../testing/test_env.py', | 443 '../../testing/test_env.py', |
444 '../../third_party/gtest-parallel/gtest-parallel', | 444 '../../third_party/gtest-parallel/gtest-parallel', |
| 445 '../../third_party/gtest-parallel/gtest_parallel.py', |
445 '../../tools_webrtc/gtest-parallel-wrapper.py', | 446 '../../tools_webrtc/gtest-parallel-wrapper.py', |
446 'base_unittests', | 447 'base_unittests', |
447 ]) | 448 ]) |
448 self.assertEqual(command, [ | 449 self.assertEqual(command, [ |
449 '../../testing/test_env.py', | 450 '../../testing/test_env.py', |
450 '../../tools_webrtc/gtest-parallel-wrapper.py', | 451 '../../tools_webrtc/gtest-parallel-wrapper.py', |
451 '--output_dir=${ISOLATED_OUTDIR}/test_logs', | 452 '--output_dir=${ISOLATED_OUTDIR}/test_logs', |
452 '--gtest_color=no', | 453 '--gtest_color=no', |
453 '--timeout=900', | 454 '--timeout=900', |
454 '--retry_failed=3', | 455 '--retry_failed=3', |
(...skipping 28 matching lines...) Expand all Loading... |
483 | 484 |
484 isolate_file = mbw.files['/fake_src/out/Default/base_unittests.isolate'] | 485 isolate_file = mbw.files['/fake_src/out/Default/base_unittests.isolate'] |
485 isolate_file_contents = ast.literal_eval(isolate_file) | 486 isolate_file_contents = ast.literal_eval(isolate_file) |
486 files = isolate_file_contents['variables']['files'] | 487 files = isolate_file_contents['variables']['files'] |
487 command = isolate_file_contents['variables']['command'] | 488 command = isolate_file_contents['variables']['command'] |
488 | 489 |
489 self.assertEqual(files, [ | 490 self.assertEqual(files, [ |
490 '../../testing/test_env.py', | 491 '../../testing/test_env.py', |
491 '../../testing/xvfb.py', | 492 '../../testing/xvfb.py', |
492 '../../third_party/gtest-parallel/gtest-parallel', | 493 '../../third_party/gtest-parallel/gtest-parallel', |
| 494 '../../third_party/gtest-parallel/gtest_parallel.py', |
493 '../../tools_webrtc/gtest-parallel-wrapper.py', | 495 '../../tools_webrtc/gtest-parallel-wrapper.py', |
494 'base_unittests', | 496 'base_unittests', |
495 'some_resource_file', | 497 'some_resource_file', |
496 ]) | 498 ]) |
497 self.assertEqual(command, [ | 499 self.assertEqual(command, [ |
498 '../../testing/xvfb.py', | 500 '../../testing/xvfb.py', |
499 '../../tools_webrtc/gtest-parallel-wrapper.py', | 501 '../../tools_webrtc/gtest-parallel-wrapper.py', |
500 '--output_dir=${ISOLATED_OUTDIR}/test_logs', | 502 '--output_dir=${ISOLATED_OUTDIR}/test_logs', |
501 '--gtest_color=no', | 503 '--gtest_color=no', |
502 '--timeout=900', | 504 '--timeout=900', |
(...skipping 29 matching lines...) Expand all Loading... |
532 '//out/Default'], mbw=mbw, ret=0) | 534 '//out/Default'], mbw=mbw, ret=0) |
533 | 535 |
534 isolate_file = mbw.files['c:\\fake_src\\out\\Default\\unittests.isolate'] | 536 isolate_file = mbw.files['c:\\fake_src\\out\\Default\\unittests.isolate'] |
535 isolate_file_contents = ast.literal_eval(isolate_file) | 537 isolate_file_contents = ast.literal_eval(isolate_file) |
536 files = isolate_file_contents['variables']['files'] | 538 files = isolate_file_contents['variables']['files'] |
537 command = isolate_file_contents['variables']['command'] | 539 command = isolate_file_contents['variables']['command'] |
538 | 540 |
539 self.assertEqual(files, [ | 541 self.assertEqual(files, [ |
540 '../../testing/test_env.py', | 542 '../../testing/test_env.py', |
541 '../../third_party/gtest-parallel/gtest-parallel', | 543 '../../third_party/gtest-parallel/gtest-parallel', |
| 544 '../../third_party/gtest-parallel/gtest_parallel.py', |
542 '../../tools_webrtc/gtest-parallel-wrapper.py', | 545 '../../tools_webrtc/gtest-parallel-wrapper.py', |
543 'some_dependency', | 546 'some_dependency', |
544 'unittests.exe', | 547 'unittests.exe', |
545 ]) | 548 ]) |
546 self.assertEqual(command, [ | 549 self.assertEqual(command, [ |
547 '../../testing/test_env.py', | 550 '../../testing/test_env.py', |
548 '../../tools_webrtc/gtest-parallel-wrapper.py', | 551 '../../tools_webrtc/gtest-parallel-wrapper.py', |
549 '--output_dir=${ISOLATED_OUTDIR}\\test_logs', | 552 '--output_dir=${ISOLATED_OUTDIR}\\test_logs', |
550 '--gtest_color=no', | 553 '--gtest_color=no', |
551 '--timeout=900', | 554 '--timeout=900', |
(...skipping 26 matching lines...) Expand all Loading... |
578 files=test_files, ret=0) | 581 files=test_files, ret=0) |
579 | 582 |
580 isolate_file = mbw.files['/fake_src/out/Default/base_unittests.isolate'] | 583 isolate_file = mbw.files['/fake_src/out/Default/base_unittests.isolate'] |
581 isolate_file_contents = ast.literal_eval(isolate_file) | 584 isolate_file_contents = ast.literal_eval(isolate_file) |
582 files = isolate_file_contents['variables']['files'] | 585 files = isolate_file_contents['variables']['files'] |
583 command = isolate_file_contents['variables']['command'] | 586 command = isolate_file_contents['variables']['command'] |
584 | 587 |
585 self.assertEqual(files, [ | 588 self.assertEqual(files, [ |
586 '../../testing/test_env.py', | 589 '../../testing/test_env.py', |
587 '../../third_party/gtest-parallel/gtest-parallel', | 590 '../../third_party/gtest-parallel/gtest-parallel', |
| 591 '../../third_party/gtest-parallel/gtest_parallel.py', |
588 '../../tools_webrtc/gtest-parallel-wrapper.py', | 592 '../../tools_webrtc/gtest-parallel-wrapper.py', |
589 'base_unittests', | 593 'base_unittests', |
590 ]) | 594 ]) |
591 self.assertEqual(command, [ | 595 self.assertEqual(command, [ |
592 '../../testing/test_env.py', | 596 '../../testing/test_env.py', |
593 '../../tools_webrtc/gtest-parallel-wrapper.py', | 597 '../../tools_webrtc/gtest-parallel-wrapper.py', |
594 '--output_dir=${ISOLATED_OUTDIR}/test_logs', | 598 '--output_dir=${ISOLATED_OUTDIR}/test_logs', |
595 '--gtest_color=no', | 599 '--gtest_color=no', |
596 '--timeout=900', | 600 '--timeout=900', |
597 '--retry_failed=3', | 601 '--retry_failed=3', |
(...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
784 self.check(['lookup', '-c', 'fake_config'], mbw=mbw, | 788 self.check(['lookup', '-c', 'fake_config'], mbw=mbw, |
785 ret=0, | 789 ret=0, |
786 out=("GYP_DEFINES='foo=bar baz=1'\n" | 790 out=("GYP_DEFINES='foo=bar baz=1'\n" |
787 "GYP_LINK_CONCURRENCY=1\n" | 791 "GYP_LINK_CONCURRENCY=1\n" |
788 "LLVM_FORCE_HEAD_REVISION=1\n" | 792 "LLVM_FORCE_HEAD_REVISION=1\n" |
789 "python build/gyp_chromium -G output_dir=_path_\n")) | 793 "python build/gyp_chromium -G output_dir=_path_\n")) |
790 | 794 |
791 | 795 |
792 if __name__ == '__main__': | 796 if __name__ == '__main__': |
793 unittest.main() | 797 unittest.main() |
OLD | NEW |