Files
nodejs24/flaky_test_rerun.patch

22 lines
667 B
Diff
Raw Normal View History

2025-11-25 09:51:29 +01:00
Index: node-v24.11.1/tools/test.py
===================================================================
--- node-v24.11.1.orig/tools/test.py
+++ node-v24.11.1/tools/test.py
@@ -601,6 +601,16 @@ class TestCase(object):
self.context.store_unexpected_output)
def Run(self):
+ reruns = 0
+ while (reruns < 5):
+ reruns += 1
+ result = self.OriginalRun()
+ if (not result.HasFailed()):
+ break
+ print("FLAKY TEST rerun: ", self.GetCommand())
+ return result
+
+ def OriginalRun(self):
try:
run_configuration = self.GetRunConfiguration()
command = run_configuration['command']