.NET Core CI #36
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: .NET Core CI | |
on: | |
push: | |
branches: [ "main" ] | |
pull_request: | |
branches: [ "main" ] | |
workflow_dispatch: | |
inputs: | |
logLevel: | |
description: 'Log level' | |
required: true | |
default: 'warning' | |
type: choice | |
options: | |
- info | |
- warning | |
- debug | |
tags: | |
description: 'Test scenario tags' | |
required: false | |
type: boolean | |
environment: | |
description: 'Environment to run tests against' | |
type: environment | |
required: false | |
jobs: | |
contract-test: | |
runs-on: macos-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup .NET | |
uses: actions/setup-dotnet@v4 | |
with: | |
dotnet-version: 8.0.x | |
- name: Restore dependencies | |
run: dotnet restore | |
- name: Build | |
run: dotnet build --no-restore | |
- name: Setup Testcontainers Cloud Client | |
uses: atomicjar/testcontainers-cloud-setup-action@v1 | |
with: | |
token: ${{ secrets.TC_CLOUD_TOKEN }} | |
wait: true | |
- name: Test | |
run: dotnet test --no-build --verbosity normal | |
- name: Upload HTML Test Report | |
uses: actions/upload-artifact@v4 | |
with: | |
name: html-report | |
path: specmatic-order-bff-csharp.test/build/reports/specmatic/html | |
- name: Run Specmatic Insights Github Build Reporter | |
uses: znsio/[email protected] | |
with: | |
github-token: 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 | |
specmatic-insights-host: https://insights.specmatic.io | |
specmatic-reports-dir: ./specmatic-order-bff-csharp.test/build/reports/specmatic | |
org-id: 66fe6c555e232d36a28fef94 | |
branch-ref: ${{ github.ref }} | |
branch-name: ${{ github.ref_name }} | |
build-id: ${{ github.run_id }} | |
repo-name: ${{ github.event.repository.name }} | |
repo-id: ${{ github.repository_id }} | |
repo-url: ${{ github.event.repository.html_url }} |