feat: update prompt config page (PR 1) #306
Workflow file for this run
This file contains 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 (Golang)' | |
on: | |
push: | |
branches: | |
- main | |
paths: | |
- '.github/workflows/tests-go.yaml' | |
- 'gen/go/**' | |
- 'go.*' | |
- 'services/api-gateway/**' | |
- 'services/dashboard-backend/**' | |
- 'shared/go/**' | |
pull_request: | |
branches: | |
- main | |
paths: | |
- 'gen/go/**' | |
- 'go.*' | |
- 'services/api-gateway/**' | |
- 'services/dashboard-backend/**' | |
- 'shared/go/**' | |
env: | |
GCP_OIDC_PROVIDER_NAME: github-provider | |
GCP_PROJECT_ID: basemind-ai-development | |
GCP_PROJECT_NUMBER: 78794879644 | |
GCP_SERVICE_ACCOUNT_NAME: firebase-adminsdk-frgvx | |
GCP_WORKLOAD_IDENTITY_POOL: dev-pool | |
TEST_SLEEP_TIMEOUT: 1s | |
DEEPSOURCE_DSN: ${{secrets.DEEPSOURCE_DSN}} | |
jobs: | |
test: | |
if: github.ref_name != 'development' && github.ref_name != 'production' | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
id-token: write | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Setup Golang | |
uses: actions/setup-go@v5 | |
with: | |
go-version: '1.21' | |
- name: Download the DeepSource CLI | |
run: curl https://deepsource.io/cli | sh | |
- name: Load cached Golang dependencies | |
id: cached-go-dependencies | |
uses: actions/cache@v3 | |
with: | |
path: | | |
~/.cache/go-build | |
~/go/pkg/mod | |
key: go-${{ inputs.go_version }}-v1.0-${{ hashFiles('**/go.sum') }} | |
- name: Install Golang dependencies | |
if: steps.cached-go-dependencies.outputs.cache-hit != 'true' | |
shell: bash | |
run: go get -v -t ./... | |
- name: Install Atlas | |
shell: bash | |
run: curl -sSf https://atlasgo.sh | sh | |
- name: Authenticate with GCP | |
id: auth | |
uses: google-github-actions/auth@v2 | |
with: | |
workload_identity_provider: projects/${{env.GCP_PROJECT_NUMBER}}/locations/global/workloadIdentityPools/${{env.GCP_WORKLOAD_IDENTITY_POOL}}/providers/${{env.GCP_OIDC_PROVIDER_NAME}} | |
service_account: ${{env.GCP_SERVICE_ACCOUNT_NAME}}@${{env.GCP_PROJECT_ID}}.iam.gserviceaccount.com | |
- name: Test | |
run: go test ./... -v -p 1 -coverprofile=cover.out | |
- name: Upload Coverage Report | |
run: ./bin/deepsource report --analyzer test-coverage --key go --value-file ./cover.out |