|
43 | 43 | run: npm run lint
|
44 | 44 |
|
45 | 45 | test:
|
46 |
| - name: |
47 |
| - 🧪 Test (Node@${{ matrix.node }} - ESLint@${{ matrix.eslint }} - ${{ |
| 46 | + name: 🧪 Test (Node@${{ matrix.node }} - ESLint@${{ matrix.eslint }} - ${{ |
48 | 47 | matrix.os }})
|
49 | 48 | strategy:
|
50 | 49 | fail-fast: false
|
@@ -118,12 +117,54 @@ jobs:
|
118 | 117 | - name: ▶️ Run test:types script
|
119 | 118 | run: npm run test:types
|
120 | 119 |
|
| 120 | + type-tests: |
| 121 | + name: 🧪 Type tests with ESLint ${{ matrix.eslint }} and TypeScript ${{ matrix.ts }} |
| 122 | + runs-on: ubuntu-latest |
| 123 | + |
| 124 | + strategy: |
| 125 | + fail-fast: false |
| 126 | + |
| 127 | + matrix: |
| 128 | + eslint: [8, 9] |
| 129 | + ts: ["5.0", "5.1", "5.2", "5.3", "5.4", "5.5", "5.6"] |
| 130 | + |
| 131 | + steps: |
| 132 | + - name: ⬇️ Checkout repo |
| 133 | + uses: actions/checkout@v4 |
| 134 | + |
| 135 | + - name: ⎔ Setup Node |
| 136 | + uses: actions/setup-node@v4 |
| 137 | + with: |
| 138 | + node-version: 18 |
| 139 | + |
| 140 | + - name: 📥 Install dependencies |
| 141 | + run: npm install |
| 142 | + |
| 143 | + - name: Pack the package |
| 144 | + id: pack |
| 145 | + run: npm install "$(npm pack | tail -n1)" |
| 146 | + |
| 147 | + - name: 📥 Uninstall @types/eslint |
| 148 | + if: matrix.eslint != 8 |
| 149 | + run: npm uninstall @types/eslint |
| 150 | + |
| 151 | + - name: 📥 Install ESLint version ${{ matrix.eslint }} |
| 152 | + run: npm install --save-dev eslint@${{ matrix.eslint }} |
| 153 | + |
| 154 | + - name: 📥 Install TypeScript version ${{ matrix.ts }} |
| 155 | + run: npm install --save-dev typescript@${{ matrix.ts }} -f |
| 156 | + |
| 157 | + - name: ▶️ Run test:types script |
| 158 | + run: npm run test:types |
| 159 | + |
| 160 | + - name: 📝 List version of ESLint |
| 161 | + run: npm why eslint @types/eslint |
| 162 | + |
121 | 163 | release:
|
122 | 164 | name: 🚀 Release
|
123 |
| - needs: [ lint, test ] |
| 165 | + needs: [lint, test] |
124 | 166 | runs-on: ubuntu-latest
|
125 |
| - if: |
126 |
| - github.repository == 'eslint-community/eslint-plugin-eslint-comments' && |
| 167 | + if: github.repository == 'eslint-community/eslint-plugin-eslint-comments' && |
127 | 168 | contains('refs/heads/main,refs/heads/next,refs/heads/beta,refs/heads/alpha',
|
128 | 169 | github.ref) && github.event_name == 'push'
|
129 | 170 | steps:
|
|
0 commit comments