Skip to content

Commit

Permalink
Merge branch 'main' into refactor-use-testTimeoutSymbol
Browse files Browse the repository at this point in the history
  • Loading branch information
mrazauskas committed Feb 8, 2022
2 parents 4d175b4 + 2f5a93d commit 6c1693e
Show file tree
Hide file tree
Showing 663 changed files with 31,682 additions and 15,560 deletions.
46 changes: 0 additions & 46 deletions .azure-pipelines-steps.yml

This file was deleted.

36 changes: 0 additions & 36 deletions .azure-pipelines.yml

This file was deleted.

8 changes: 3 additions & 5 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ aliases:
app-dir: ~/jest

orbs:
node: circleci/node@4.7.0
node: circleci/node@5.0.0

jobs:
test-node:
Expand All @@ -28,7 +28,6 @@ jobs:
- checkout
- node/install:
node-version: << parameters.node-version >>
install-npm: false
- node/install-packages: *install
- when:
condition: << parameters.partial >>
Expand All @@ -49,8 +48,7 @@ jobs:
steps:
- checkout
- node/install:
node-version: '14'
install-npm: false
node-version: lts/*
- node/install-packages: *install
- run:
command: JEST_JASMINE=1 yarn test-ci-partial && JEST_JASMINE=1 yarn test-leak
Expand All @@ -64,7 +62,7 @@ workflows:
- test-node:
matrix:
parameters:
node-version: ['14']
node-version: ['lts/*']
- test-node:
name: test-node-partial-<< matrix.node-version >>
partial: true
Expand Down
1 change: 1 addition & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
bin/
flow-typed/**
packages/*/build/**
packages/*/dist/**
packages/jest-diff/src/cleanupSemantic.ts
website/.docusaurus
website/blog
Expand Down
39 changes: 29 additions & 10 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,10 @@
* LICENSE file in the root directory of this source tree.
*/

const {sync: readPkg} = require('read-pkg');
const {getPackages} = require('./scripts/buildUtils');

const internalPackages = getPackages()
.map(packageDir => {
const pkg = readPkg({cwd: packageDir});

return pkg.name;
})
.map(({pkg}) => pkg.name)
.sort();

module.exports = {
Expand Down Expand Up @@ -100,7 +95,6 @@ module.exports = {
'packages/expect/src/matchers.ts',
'packages/expect/src/print.ts',
'packages/expect/src/toThrowMatchers.ts',
'packages/expect/src/types.ts',
'packages/expect/src/utils.ts',
'packages/jest-core/src/ReporterDispatcher.ts',
'packages/jest-core/src/TestScheduler.ts',
Expand Down Expand Up @@ -161,6 +155,17 @@ module.exports = {
'sort-keys': 'off',
},
},
// snapshots in examples plus inline snapshots need to keep backtick
{
files: ['*.md', 'e2e/custom-inline-snapshot-matchers/__tests__/*'],
rules: {
quotes: [
'error',
'single',
{allowTemplateLiterals: true, avoidEscape: true},
],
},
},
{
files: ['website/**/*'],
rules: {
Expand All @@ -186,6 +191,18 @@ module.exports = {
files: 'packages/**/*.ts',
rules: {
'@typescript-eslint/explicit-module-boundary-types': 'error',
'import/no-anonymous-default-export': [
'error',
{
allowAnonymousClass: false,
allowAnonymousFunction: false,
allowArray: false,
allowArrowFunction: false,
allowCallExpression: false,
allowLiteral: false,
allowObject: true,
},
],
},
},
{
Expand Down Expand Up @@ -234,7 +251,7 @@ module.exports = {
},
},
{
files: ['**/__typechecks__/**', '*.md'],
files: ['**/__typetests__/**', '*.md'],
rules: {
'jest/no-focused-tests': 'off',
'jest/no-identical-title': 'off',
Expand All @@ -259,11 +276,13 @@ module.exports = {
'website/**',
'**/__mocks__/**',
'**/__tests__/**',
'**/__typetests__/**',
'**/__performance_tests__/**',
'packages/diff-sequences/perf/index.js',
'packages/pretty-format/perf/test.js',
],
rules: {
'@typescript-eslint/no-unused-vars': 'off',
'import/no-unresolved': 'off',
'no-console': 'off',
'no-unused-vars': 'off',
Expand Down Expand Up @@ -303,7 +322,7 @@ module.exports = {
devDependencies: [
'**/__mocks__/**',
'**/__tests__/**',
'**/__typechecks__/**',
'**/__typetests__/**',
'**/?(*.)(spec|test).js?(x)',
'scripts/**',
'babel.config.js',
Expand Down Expand Up @@ -461,7 +480,7 @@ module.exports = {
quotes: [
'error',
'single',
{allowTemplateLiterals: true, avoidEscape: true},
{allowTemplateLiterals: false, avoidEscape: true},
],
radix: 'warn',
'require-jsdoc': 'off',
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/nodejs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:

- uses: actions/setup-node@v2
with:
node-version: 14.x
node-version: lts/*
cache: yarn

- name: Validate cache
Expand All @@ -46,7 +46,7 @@ jobs:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: 12.x
node-version: lts/*
cache: yarn
- name: install
run: yarn --immutable
Expand Down Expand Up @@ -114,10 +114,10 @@ jobs:
git config --global core.symlinks true
if: runner.os == 'Windows'
- uses: actions/checkout@v2
- name: Use Node.js 14.x
- name: Use Node.js LTS
uses: actions/setup-node@v2
with:
node-version: 14.x
node-version: lts/*
cache: yarn
- name: install
run: yarn --immutable
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
/node_modules

/packages/*/build/
/packages/*/dist/
/packages/*/coverage/
/packages/*/node_modules/

Expand All @@ -40,6 +41,7 @@ junit.xml
package-lock.json

*.tsbuildinfo
api-extractor.json

# https://yarnpkg.com/getting-started/qa#which-files-should-be-gitignored but nested for e2e directories
**/.yarn/*
Expand Down
5 changes: 0 additions & 5 deletions .npmignore

This file was deleted.

8 changes: 8 additions & 0 deletions .yarnrc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,14 @@ enableGlobalCache: true

nodeLinker: node-modules

packageExtensions:
react-native@*:
peerDependencies:
"@babel/preset-env": "^7.1.6"
react-native-codegen@*:
peerDependencies:
"@babel/preset-env": "^7.1.6"

plugins:
- path: .yarn/plugins/@yarnpkg/plugin-interactive-tools.cjs
spec: "@yarnpkg/plugin-interactive-tools"
Expand Down
Loading

0 comments on commit 6c1693e

Please sign in to comment.