Skip to content

Commit 10c24fe

Browse files
committed
♻️ Use all test data
Removes random selection of test cases.
1 parent aabd18f commit 10c24fe

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

cvss40.test.js

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,9 @@ describe('CVSS 4.0', () => {
1919
return data;
2020
}, {});
2121

22-
const randomlyPickFrom = (count, array) => array.slice(0, count).sort(() => 0.5 - Math.random());
2322
Object.entries(testData).forEach(([fileName, vectorScores]) => {
24-
const count = 10000;
25-
it(`should calculate ${count} random scores in ${fileName} correctly`, () => {
26-
randomlyPickFrom(count, vectorScores).forEach(({ vector, score }) => {
23+
it(`should calculate scores in ${fileName} correctly`, () => {
24+
vectorScores.forEach(({ vector, score }) => {
2725
expect(new CVSS40(vector).score).toBe(score);
2826
});
2927
});

0 commit comments

Comments
 (0)