Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(2)

Delta Between Two Patch Sets: Lib/test/test_regrtest.py

Issue 26295: Random failures when running test suite in parallel (-m test -j0) caused by test_regrtest
Left Patch Set: Created 3 years, 11 months ago
Right Patch Set: Created 3 years, 11 months ago
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
Left: Side by side diff | Download
Right: Side by side diff | Download
« no previous file with change/comment | « Lib/test/libregrtest/setup.py ('k') | Lib/test/test_zipfile.py » ('j') | no next file with change/comment »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
LEFTRIGHT
1 """ 1 """
2 Tests of regrtest.py. 2 Tests of regrtest.py.
3 3
4 Note: test_regrtest cannot be run twice in parallel. 4 Note: test_regrtest cannot be run twice in parallel.
5 """ 5 """
6 6
7 import argparse 7 import argparse
8 import contextlib 8 import contextlib
9 import faulthandler 9 import faulthandler
10 import getopt 10 import getopt
(...skipping 433 matching lines...) Expand 10 before | Expand all | Expand 10 after
444 "stderr:\n" 444 "stderr:\n"
445 "---\n" 445 "---\n"
446 "%s" 446 "%s"
447 "---\n" 447 "---\n"
448 % proc.stderr) 448 % proc.stderr)
449 self.fail(msg) 449 self.fail(msg)
450 return proc 450 return proc
451 451
452 452
453 def run_python(self, args, **kw): 453 def run_python(self, args, **kw):
454 args = [sys.executable, '-X', 'faulthandler', 454 args = [sys.executable, '-X', 'faulthandler', '-I', *args]
455 #'-I',
456 *args]
457 proc = self.run_command(args, **kw) 455 proc = self.run_command(args, **kw)
458 return proc.stdout 456 return proc.stdout
459 457
460 458
461 class ProgramsTestCase(BaseTestCase): 459 class ProgramsTestCase(BaseTestCase):
462 """ 460 """
463 Test various ways to run the Python test suite. Use options close 461 Test various ways to run the Python test suite. Use options close
464 to options used on the buildbot. 462 to options used on the buildbot.
465 """ 463 """
466 464
(...skipping 291 matching lines...) Expand 10 before | Expand all | Expand 10 after
758 def test_list_tests(self): 756 def test_list_tests(self):
759 # test --list-tests 757 # test --list-tests
760 tests = [self.create_test() for i in range(5)] 758 tests = [self.create_test() for i in range(5)]
761 output = self.run_tests('--list-tests', *tests) 759 output = self.run_tests('--list-tests', *tests)
762 self.assertEqual(output.rstrip().splitlines(), 760 self.assertEqual(output.rstrip().splitlines(),
763 tests) 761 tests)
764 762
765 763
766 if __name__ == '__main__': 764 if __name__ == '__main__':
767 unittest.main() 765 unittest.main()
LEFTRIGHT

RSS Feeds Recent Issues | This issue
This is Rietveld 894c83f36cb7+