Tests #1222
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: Tests | |
| on: | |
| push: | |
| pull_request: | |
| branches: | |
| - main | |
| workflow_dispatch: | |
| schedule: | |
| - cron: '0 0 * * *' | |
| jobs: | |
| Tests: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| # TradingView authenticated tests use the same account/session secrets. | |
| # Running every Node matrix job at once makes the external websocket tests flaky. | |
| max-parallel: 1 | |
| matrix: | |
| node-version: [14.x, 18.x, 19.x] | |
| steps: | |
| - uses: actions/checkout@v2 | |
| - name: Use Node.js ${{ matrix.node-version }} | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: ${{ matrix.node-version }} | |
| cache: 'npm' | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Run tests | |
| run: npm test -- --run | |
| env: | |
| SESSION: ${{ secrets.TW_SESSION }} | |
| SIGNATURE: ${{ secrets.TW_SIGNATURE }} |