@samitouri / QOS-React / commits / 164af898c4

[ci] Remove jestSequencer

This was previously used for circleci parallelization but is no longer needed. ghstack-source-id: d8c1005e0955310b0ae10111459e0b51d4176b69 Pull Request resolved: https://github.com/facebook/react/pull/30500

Lauren Tan committed Jul 29, 2024 at 12:55 UTC 164af898c43d71840e46d6c5530aae898337ef0e
2 files changed -21
scripts/jest/config.base.js
-2
@@ -24,8 +24,6 @@ module.exports = {
24 },
25 snapshotSerializers: [require.resolve('jest-snapshot-serializer-raw')],
26
27 - testSequencer: require.resolve('./jestSequencer'),
28 -
27 testEnvironment: 'jsdom',
28
29 testRunner: 'jest-circus/runner',
scripts/jest/jestSequencer.js deleted
-19
@@ -1,19 +0,0 @@
1 -'use strict';
2 -
3 -const Sequencer = require('@jest/test-sequencer').default;
4 -
5 -class CustomSequencer extends Sequencer {
6 - sort(tests) {
7 - if (process.env.CIRCLE_NODE_TOTAL) {
8 - // In CI, parallelize tests across multiple tasks.
9 - const nodeTotal = parseInt(process.env.CIRCLE_NODE_TOTAL, 10);
10 - const nodeIndex = parseInt(process.env.CIRCLE_NODE_INDEX, 10);
11 - tests = tests
12 - .sort((a, b) => (a.path < b.path ? -1 : 1))
13 - .filter((_, i) => i % nodeTotal === nodeIndex);
14 - }
15 - return tests;
16 - }
17 -}
18 -
19 -module.exports = CustomSequencer;