openai/openai-dotnet

Public

mirrored from https://github.com/openai/openai-dotnetAvailable

CodeCommitsIssuesPull requestsActionsInsightsSecurity
OpenAI_2.3.0

Branches

Tags

  • No tags available.
0Branches0Tags
Go to file
Add file
Code

Clone

HTTPS

Download ZIP

.github/workflows/live-test.yml

47lines · modecode

1# This workflow is triggered by the user and runs live tests on the codebase.
2name: Live Test
3
4on:
5 workflow_dispatch:
6 pull_request:
7 types:
8 - labeled
9
10jobs:
11 test:
12 name: Live Test
13 runs-on: ubuntu-latest
14 if: github.event_name == 'workflow_dispatch' || contains(github.event.pull_request.labels.*.name, 'live test')
15 environment: Live Testing
16 env:
17 version_suffix_args: ${{ format('/p:VersionSuffix="alpha.{0}"', github.run_number) }}
18 steps:
19 - name: Setup .NET
20 uses: actions/setup-dotnet@v3
21 with:
22 dotnet-version: '9.x'
23
24 - name: Setup .NET 8
25 uses: actions/setup-dotnet@v3
26 with:
27 dotnet-version: '8.x'
28
29 - name: Checkout code
30 uses: actions/checkout@v2
31
32 - name: Run live tests
33 run: dotnet test ./tests/OpenAI.Tests.csproj
34 --configuration Release
35 --filter="TestCategory!=Smoke&TestCategory!=Assistants&TestCategory!=StoredChat&TestCategory!=Images&TestCategory!=Uploads&TestCategory!=Moderations&TestCategory!=FineTuning&TestCategory!=Conversation&TestCategory!=Manual"
36 --logger "trx;LogFilePrefix=live"
37 --results-directory ${{github.workspace}}/artifacts/test-results
38 ${{ env.version_suffix_args}}
39 env:
40 OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
41
42 - name: Upload artifact
43 uses: actions/upload-artifact@v4
44 if: ${{ !cancelled() }}
45 with:
46 name: test-artifacts
47 path: ${{github.workspace}}/artifacts
48