Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: jest-community/eslint-plugin-jest
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v24.1.0
Choose a base ref
...
head repository: jest-community/eslint-plugin-jest
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v24.1.1
Choose a head ref
  • 16 commits
  • 32 files changed
  • 7 contributors

Commits on Oct 5, 2020

  1. Use dedent some more (#685)

    * test(require-top-level-describe): use dedent for all cases
    
    * test(require-to-throw-message): use dedent for all cases
    
    * test(prefer-todo): use dedent for all cases
    
    * test(prefer-hooks-on-top): use dedent for all cases
    G-Rath authored Oct 5, 2020
    Copy the full SHA
    79fd5e7 View commit details

Commits on Oct 12, 2020

  1. Copy the full SHA
    e5f9c21 View commit details

Commits on Oct 14, 2020

  1. Copy the full SHA
    133a706 View commit details

Commits on Oct 17, 2020

  1. chore: enable eslint-plugin/test-case-property-ordering rule (#684)

    * chore: enable `eslint-plugin/test-case-property-ordering` rule
    
    * chore: remove old comment
    G-Rath authored Oct 17, 2020
    Copy the full SHA
    a5de8e3 View commit details
  2. docs(valid-title): reduce ambiguity (#694)

    * docs: made valid-title docs a little more clear
    
    * docs(valid-title): reduce ambiguity
    
    Co-authored-by: Gareth Jones <Jones258@Gmail.com>
    golergka and G-Rath authored Oct 17, 2020
    Copy the full SHA
    fa68c88 View commit details

Commits on Oct 19, 2020

  1. Copy the full SHA
    54c20e0 View commit details
  2. Copy the full SHA
    8471ff3 View commit details

Commits on Oct 26, 2020

  1. Copy the full SHA
    9d157e6 View commit details

Commits on Oct 27, 2020

  1. chore(ci): test on node v15

    SimenB authored Oct 27, 2020
    Copy the full SHA
    1480f2e View commit details
  2. Copy the full SHA
    87f7162 View commit details

Commits on Nov 2, 2020

  1. Copy the full SHA
    c611749 View commit details
  2. Copy the full SHA
    7262fe4 View commit details

Commits on Nov 4, 2020

  1. Copy the full SHA
    219bb12 View commit details

Commits on Nov 9, 2020

  1. Copy the full SHA
    8e906ad View commit details

Commits on Nov 12, 2020

  1. fix: improve support for it.each involving tagged template literals (#…

    …701)
    
    * fix(no-disabled-tests): fix bug with it.each
    
    * fix(no-test-prefixes): fix bug with it.each
    
    * fix(consistent-test-it): fix bug with it.each
    
    * fix(no-standalone-expect): coverage back to 100%
    
    * fix: code review changes
    k-yle authored Nov 12, 2020
    Copy the full SHA
    2341814 View commit details
  2. chore(release): 24.1.1 [skip ci]

    ## [24.1.1](v24.1.0...v24.1.1) (2020-11-12)
    
    ### Bug Fixes
    
    * improve support for it.each involving tagged template literals ([#701](#701)) ([2341814](2341814))
    semantic-release-bot committed Nov 12, 2020
    Copy the full SHA
    ce08024 View commit details
Showing with 1,761 additions and 1,553 deletions.
  1. +1 −1 .eslintrc.js
  2. +0 −1 .github/renovate.json
  3. +4 −4 .github/workflows/lint.yml
  4. +5 −7 .github/workflows/nodejs.yml
  5. +9 −12 .github/workflows/release.yml
  6. +7 −0 CHANGELOG.md
  7. +1 −1 docs/rules/valid-title.md
  8. +1 −1 package.json
  9. +104 −32 src/rules/__tests__/consistent-test-it.test.ts
  10. +3 −3 src/rules/__tests__/lowercase-name.test.ts
  11. +14 −14 src/rules/__tests__/no-alias-methods.test.ts
  12. +33 −0 src/rules/__tests__/no-disabled-tests.test.ts
  13. +6 −6 src/rules/__tests__/no-jasmine-globals.test.ts
  14. +18 −18 src/rules/__tests__/no-large-snapshots.test.ts
  15. +4 −0 src/rules/__tests__/no-standalone-expect.test.ts
  16. +66 −6 src/rules/__tests__/no-test-prefixes.test.ts
  17. +96 −104 src/rules/__tests__/prefer-hooks-on-top.test.ts
  18. +2 −2 src/rules/__tests__/prefer-inline-snapshots.test.ts
  19. +11 −11 src/rules/__tests__/prefer-spy-on.test.ts
  20. +8 −8 src/rules/__tests__/prefer-to-be-null.test.ts
  21. +8 −8 src/rules/__tests__/prefer-to-be-undefined.test.ts
  22. +25 −25 src/rules/__tests__/prefer-to-contain.test.ts
  23. +3 −3 src/rules/__tests__/prefer-to-have-length.test.ts
  24. +8 −7 src/rules/__tests__/prefer-todo.test.ts
  25. +32 −21 src/rules/__tests__/require-to-throw-message.test.ts
  26. +24 −23 src/rules/__tests__/require-top-level-describe.test.ts
  27. +41 −41 src/rules/__tests__/valid-title.test.ts
  28. +7 −2 src/rules/consistent-test-it.ts
  29. +7 −0 src/rules/no-disabled-tests.ts
  30. +11 −3 src/rules/no-test-prefixes.ts
  31. +15 −1 src/rules/utils.ts
  32. +1,187 −1,188 yarn.lock
2 changes: 1 addition & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
@@ -36,6 +36,7 @@ module.exports = {
'@typescript-eslint/ban-types': 'error',
'@typescript-eslint/no-unused-vars': 'error',
'eslint-comments/no-unused-disable': 'error',
'eslint-plugin/test-case-property-ordering': 'error',
'no-else-return': 'error',
'no-negated-condition': 'error',
eqeqeq: ['error', 'smart'],
@@ -73,7 +74,6 @@ module.exports = {
{ blankLine: 'any', prev: 'directive', next: 'directive' },
],

// todo: pulled from v3 of @typescript-eslint's eslint-recommended config
'prefer-spread': 'error',
'prefer-rest-params': 'error',
'prefer-const': ['error', { destructuring: 'all' }],
1 change: 0 additions & 1 deletion .github/renovate.json
Original file line number Diff line number Diff line change
@@ -2,6 +2,5 @@
"extends": ["config:base"],
"lockFileMaintenance": { "enabled": true },
"rangeStrategy": "replace",
"ignorePresets": ["group:semantic-releaseMonorepo"],
"postUpdateOptions": ["yarnDedupeHighest"]
}
8 changes: 4 additions & 4 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -25,12 +25,12 @@ jobs:
- uses: actions/cache@v2
with:
path: ${{ steps.yarn-cache.outputs.dir }}
key: ubuntu-latest-node-12.x-yarn-${{ hashFiles('**/yarn.lock') }}
key: ubuntu-latest-node-14.x-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
ubuntu-latest-node-12.x-yarn-
ubuntu-latest-node-14.x-yarn-
- uses: actions/setup-node@v2.1.2
with:
node-version: 12.x
node-version: 14.x
- name: install
run: yarn
- name: regenerate docs
@@ -45,6 +45,6 @@ jobs:
steps:
- uses: actions/checkout@v2
- name: Danger
uses: danger/danger-js@10.5.0
uses: danger/danger-js@10.5.1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
12 changes: 5 additions & 7 deletions .github/workflows/nodejs.yml
Original file line number Diff line number Diff line change
@@ -18,7 +18,7 @@ jobs:
strategy:
fail-fast: false
matrix:
node-version: [10.x, 12.x, 14.x]
node-version: [10.x, 12.x, 14.x, 15.x]
eslint-version: [5, 6, 7]
runs-on: ubuntu-latest

@@ -50,7 +50,7 @@ jobs:
run: yarn test --coverage ${{ matrix.eslint-version >= 6 }}
env:
CI: true
- uses: codecov/codecov-action@v1.0.13
- uses: codecov/codecov-action@v1.0.14
if: ${{ matrix.eslint-version >= 6 }}
test-os:
name: Test on ${{ matrix.os }} using Node.js LTS
@@ -68,14 +68,12 @@ jobs:
- uses: actions/cache@v2
with:
path: ${{ steps.yarn-cache.outputs.dir }}
key:
${{ runner.os }}-node-${{ matrix.node-version }}-yarn-${{
hashFiles('**/yarn.lock') }}
key: ${{ runner.os }}-node-14.x-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-node-${{ matrix.node-version }}-yarn-
${{ runner.os }}-node-14.x-yarn-
- uses: actions/setup-node@v2.1.2
with:
node-version: 12.x
node-version: 14.x
- name: install
run: yarn
- name: run prettier
21 changes: 9 additions & 12 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
name: Release
on:
push:
branches:
- master
workflow_run:
workflows: [Lint, 'Unit tests']
branches: [master]
types:
- completed

jobs:
release:
if: ${{ github.event.workflow_run.conclusion == 'success' }}
name: release
runs-on: ubuntu-latest
steps:
@@ -16,20 +19,14 @@ jobs:
- uses: actions/cache@v2
with:
path: ${{ steps.yarn-cache.outputs.dir }}
key: ubuntu-latest-node-12.x-yarn-${{ hashFiles('**/yarn.lock') }}
key: ubuntu-latest-node-14.x-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
ubuntu-latest-node-12.x-yarn-
ubuntu-latest-node-14.x-yarn-
- uses: actions/setup-node@v2.1.2
with:
node-version: 12.x
node-version: 14.x
- name: install
run: yarn
- name: run prettier
run: yarn prettier:check
- name: run typecheck
run: yarn typecheck
- name: run tests
run: yarn test --coverage
- run: yarn semantic-release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
## [24.1.1](https://github.com/jest-community/eslint-plugin-jest/compare/v24.1.0...v24.1.1) (2020-11-12)


### Bug Fixes

* improve support for it.each involving tagged template literals ([#701](https://github.com/jest-community/eslint-plugin-jest/issues/701)) ([2341814](https://github.com/jest-community/eslint-plugin-jest/commit/2341814060b38c55728c0b456d7b432f1e0e1a11))

# [24.1.0](https://github.com/jest-community/eslint-plugin-jest/compare/v24.0.2...v24.1.0) (2020-10-05)


2 changes: 1 addition & 1 deletion docs/rules/valid-title.md
Original file line number Diff line number Diff line change
@@ -43,7 +43,7 @@ xtest('foo', () => {});

**titleMustBeString**

Titles for test blocks should always be a string literal or expression.
Titles for test blocks should always be a string.

This is also applied to `describe` blocks by default, but can be turned off via
the `ignoreTypeOfDescribeName` option:
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "eslint-plugin-jest",
"version": "24.1.0",
"version": "24.1.1",
"description": "Eslint rules for Jest",
"keywords": [
"eslint",
Loading