git.delta.rocks / unique-network / refs/commits / b66d0b01b670

difftreelog

source

.github/workflows/tests_codestyle.yml1.5 KiBsourcehistory
1name: Tests code style23on:4  pull_request:5    branches:6      - develop7    types:8      - opened9      - reopened10      - synchronize11jobs:12  code_style:13    runs-on: self-hosted-ci1415    steps:16      - name: Skip if pull request is in Draft17        # `if: github.event.pull_request.draft == true` should be kept here, at18        # the step level, rather than at the job level. The latter is not19        # recommended because when the PR is moved from "Draft" to "Ready to20        # review" the workflow will immediately be passing (since it was skipped),21        # even though it hasn't actually ran, since it takes a few seconds for22        # the workflow to start. This is also disclosed in:23        # https://github.community/t/dont-run-actions-on-draft-pull-requests/16817/1724        # That scenario would open an opportunity for the check to be bypassed:25        # 1. Get your PR approved26        # 2. Move it to Draft27        # 3. Push whatever commits you want28        # 4. Move it to "Ready for review"; now the workflow is passing (it was29        #    skipped) and "Check reviews" is also passing (it won't be updated30        #    until the workflow is finished)31        if: github.event.pull_request.draft == true32        run: exit 13334      - uses: actions/checkout@v33536      - uses: actions/setup-node@v337        with:38          node-version: 163940      - name: Install modules41        run: cd tests && yarn42      - name: Run ESLint43        run: cd tests && yarn eslint --ext .ts,.js src/