fix commitId tracking logic to ensure correct SHA after amend #53
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: javascript-CI | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main, master] | |
| permissions: write-all | |
| jobs: | |
| ci_to_main: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Run Unit Tests | |
| run: npx jest --verbose --coverage | |
| - name: Jest coverage report | |
| uses: ArtiomTr/jest-coverage-report-action@v2.2.6 | |
| id: coverage | |
| with: | |
| output: report-markdown, comment | |
| - uses: marocchino/sticky-pull-request-comment@v2 | |
| with: | |
| message: ${{ steps.coverage.outputs.report }} | |
| ##### | |
| #- name: Run E2E Tests | |
| # uses: cypress-io/github-action@v4 | |
| # with: | |
| # start: npm start | |
| # wait-on: "http://localhost:1234" | |
| ##### | |
| #- name: Build for deploy | |
| # run: npm run build | |
| #- name: Deploy to GitHub Pages | |
| # if: success() | |
| # uses: crazy-max/ghaction-github-pages@v2 | |
| # with: | |
| # target_branch: gh-pages | |
| # build_dir: dist | |
| # env: | |
| # GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |