You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
test('EVALUATOR / should return label exception, treatment control and config null on error',async()=>{
29
32
constexpectedOutput={
30
33
treatment: 'control',
@@ -37,6 +40,7 @@ test('EVALUATOR / should return label exception, treatment control and config nu
37
40
'throw_exception',
38
41
null,
39
42
mockStorage,
43
+
fallbackTreatmentsCalculator
40
44
);
41
45
42
46
// This validation is async because the only exception possible when retrieving a Split would happen with Async storages.
@@ -61,6 +65,7 @@ test('EVALUATOR / should return right label, treatment and config if storage ret
61
65
'config',
62
66
null,
63
67
mockStorage,
68
+
fallbackTreatmentsCalculator
64
69
);
65
70
expect(evaluationWithConfig).toEqual(expectedOutput);// If the split is retrieved successfully we should get the right evaluation result, label and config.
66
71
@@ -70,6 +75,7 @@ test('EVALUATOR / should return right label, treatment and config if storage ret
70
75
'not_existent_split',
71
76
null,
72
77
mockStorage,
78
+
fallbackTreatmentsCalculator
73
79
);
74
80
expect(evaluationNotFound).toEqual(expectedOutputControl);// If the split is not retrieved successfully because it does not exist, we should get the right evaluation result, label and config.
75
81
@@ -79,6 +85,7 @@ test('EVALUATOR / should return right label, treatment and config if storage ret
79
85
'regular',
80
86
null,
81
87
mockStorage,
88
+
fallbackTreatmentsCalculator
82
89
);
83
90
expect(evaluation).toEqual({ ...expectedOutput,config: null});// If the split is retrieved successfully we should get the right evaluation result, label and config. If Split has no config it should have config equal null.
84
91
@@ -88,6 +95,7 @@ test('EVALUATOR / should return right label, treatment and config if storage ret
expect(multipleEvaluationAtOnce['config']).toEqual(expectedOutput['config']);// If the split is retrieved successfully we should get the right evaluation result, label and config.
@@ -134,7 +138,8 @@ describe('EVALUATOR - Multiple evaluations at once by flag sets', () => {
0 commit comments