Skip to content

Commit

Permalink
revert operators to fix budget tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Durieux Pol committed Apr 15, 2024
1 parent 98655b7 commit 55d8d5b
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 6 deletions.
4 changes: 3 additions & 1 deletion src/MuTalk-Tests/MTBudgetTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,9 @@ MTBudgetTest >> runAnalysisWithBudget: aBudget on: classesToMutate withTests: te
testClasses: testCases;
classesToMutate: classesToMutate;
budget: aBudget;
operators: MTAbstractMutantOperator contents.
operators:
(MTParseRewriterMutantOperator allConcreteSubclasses
collect: [ :operator | operator new ]).

analysis run.
^ analysis generalResult
Expand Down
4 changes: 2 additions & 2 deletions src/MuTalk-Tests/MTFixedNumberOfMutantsBudgetTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ MTFixedNumberOfMutantsBudgetTest >> runAnalysisForFixedNumberOfMutants: aNumber
{ #category : 'tests' }
MTFixedNumberOfMutantsBudgetTest >> testEvaluateAllMutantsWithConstraintGreaterThanActualNumberOfMutations [

self runAnalysisForFixedNumberOfMutants: 100.
self runAnalysisForFixedNumberOfMutants: 50.
self
assert: analysis generalResult numberOfEvaluatedMutants
equals: 96
equals: 25
]

{ #category : 'tests' }
Expand Down
6 changes: 3 additions & 3 deletions src/MuTalk-Tests/MTPercentageOfMutantsBudgetTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ MTPercentageOfMutantsBudgetTest >> testEvaluateZeroPercentOfMutantsWithZeroPerce
{ #category : 'tests' }
MTPercentageOfMutantsBudgetTest >> testExactPercentageOfMutants [

self runAnalysisForPercentageOfMutants: 25.
self assert: self percentageOfEvaluatedMutants equals: 25
self runAnalysisForPercentageOfMutants: 20.
self assert: self percentageOfEvaluatedMutants equals: 20
]

{ #category : 'tests' }
Expand All @@ -56,5 +56,5 @@ MTPercentageOfMutantsBudgetTest >> testNonExactPercentageOfMutants [
self assert: self percentageOfEvaluatedMutants >= 21.
self
assert: analysis generalResult numberOfEvaluatedMutants
equals: 21
equals: 6
]

0 comments on commit 55d8d5b

Please sign in to comment.