Skip to content

[Scheduled] Update securities list #271

[Scheduled] Update securities list

[Scheduled] Update securities list #271

Workflow file for this run

on:
push:
branches:
- main
pull_request:
branches:
- main
name: tests
env:
GO111MODULE: on
permissions:
contents: read
jobs:
test:
permissions:
actions: write # for styfle/cancel-workflow-action to cancel/stop running workflows
contents: read # for actions/checkout to fetch code
strategy:
matrix:
go-version: [1.x, 1.19.x]
platform: [ubuntu-latest]
include:
# only update test coverage stats with the most recent go version on linux
- go-version: 1.x
platform: ubuntu-latest
update-coverage: true
runs-on: ${{ matrix.platform }}
steps:
- name: Cancel previous
uses: styfle/cancel-workflow-action@01ce38bf961b4e243a6342cbade0dbc8ba3f0432 #0.12.0
with:
access_token: ${{ github.token }}
- uses: actions/checkout@v4
- uses: actions/setup-go@v4
with:
go-version: ${{ matrix.go-version }}
- name: Ensure go generate produces a zero diff
shell: bash
run: go generate -x ./... && git diff --exit-code; code=$?; git checkout -- .; (exit $code)
- name: Run go integration test
run: go test -v ./test/integration
- name: Run go test
run: go test -v -race -coverprofile coverage.txt ./twstock
- name: Upload coverage to Codecov
if: ${{ matrix.update-coverage }}
uses: codecov/codecov-action@eaaf4bedf32dbdc6b720b63067d99c4d77d6047d #v3.1.4