Skip to content

Commit 6eb6031

Browse files
committed
test: update verdict expectations from LOW to HIGH
Update all test expectations to match the corrected verdict calculation that returns 'HIGH' when violations are found (matching severity level).
1 parent 02a89e1 commit 6eb6031

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

__tests__/slop-analyzers.test.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2019,7 +2019,7 @@ module.exports = { helper };
20192019
expect(result.violations.length).toBe(1);
20202020
expect(result.violations[0].varName).toBe('redisClient');
20212021
expect(result.violations[0].type).toBe('RedisClient');
2022-
expect(result.verdict).toBe('LOW');
2022+
expect(result.verdict).toBe('HIGH');
20232023
});
20242024

20252025
it('should not flag client used in same file', () => {
@@ -2120,7 +2120,7 @@ module.exports = {};
21202120
expect(result.usagesFound).toBe(0);
21212121
expect(result.violations.length).toBe(1);
21222122
expect(result.violations[0].varName).toBe('dbConnection');
2123-
expect(result.verdict).toBe('LOW');
2123+
expect(result.verdict).toBe('HIGH');
21242124
});
21252125
});
21262126

@@ -2169,7 +2169,7 @@ if __name__ == '__main__':
21692169
expect(result.usagesFound).toBe(0);
21702170
expect(result.violations.length).toBe(1);
21712171
expect(result.violations[0].varName).toBe('redis_client');
2172-
expect(result.verdict).toBe('LOW');
2172+
expect(result.verdict).toBe('HIGH');
21732173
});
21742174
});
21752175

@@ -2220,7 +2220,7 @@ func main() {
22202220
expect(result.usagesFound).toBe(0);
22212221
expect(result.violations.length).toBe(1);
22222222
expect(result.violations[0].varName).toBe('redisClient');
2223-
expect(result.verdict).toBe('LOW');
2223+
expect(result.verdict).toBe('HIGH');
22242224
});
22252225

22262226
it('should not flag Go client used in function', () => {
@@ -2319,7 +2319,7 @@ fn main() {
23192319
expect(result.usagesFound).toBe(0);
23202320
expect(result.violations.length).toBe(1);
23212321
expect(result.violations[0].varName).toBe('redis_client');
2322-
expect(result.verdict).toBe('LOW');
2322+
expect(result.verdict).toBe('HIGH');
23232323
});
23242324
});
23252325

0 commit comments

Comments
 (0)