Skip to content

Commit 3109674

Browse files
committed
bump to 6.
I have never seen any good optimization with 5 passed test cases.
1 parent ba6a1c0 commit 3109674

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

codeflash/code_utils/config_consts.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,4 @@
88
N_TESTS_TO_GENERATE = 2
99
TOTAL_LOOPING_TIME = 10.0 # 10 second candidate benchmarking budget
1010
COVERAGE_THRESHOLD = 60.0
11+
MIN_TESTCASE_PASSED_THRESHOLD = 6

codeflash/result/critic.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
from codeflash.cli_cmds.console import logger
66
from codeflash.code_utils import env_utils
7-
from codeflash.code_utils.config_consts import COVERAGE_THRESHOLD, MIN_IMPROVEMENT_THRESHOLD
7+
from codeflash.code_utils.config_consts import COVERAGE_THRESHOLD, MIN_IMPROVEMENT_THRESHOLD, MIN_TESTCASE_PASSED_THRESHOLD
88
from codeflash.models.models import TestType
99

1010
if TYPE_CHECKING:
@@ -50,7 +50,7 @@ def quantity_of_tests_critic(candidate_result: OptimizedCandidateResult) -> bool
5050
for test_type in report:
5151
pass_count += report[test_type]["passed"]
5252

53-
if pass_count >= 4:
53+
if pass_count >= MIN_TESTCASE_PASSED_THRESHOLD:
5454
return True
5555
# If only one test passed, check if it's a REPLAY_TEST
5656
return bool(pass_count == 1 and report[TestType.REPLAY_TEST]["passed"] == 1)

0 commit comments

Comments
 (0)