File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -3,15 +3,15 @@ name: Run Selenium Tests
33on :
44 push :
55 branches :
6- - master # Triggers on push to master
6+ - master
77 pull_request :
88 branches :
9- - master # Triggers on pull request targeting master
10- workflow_dispatch : # Allows manual trigger from GitHub UI
9+ - master
10+ workflow_dispatch :
1111
1212jobs :
1313 test :
14- runs-on : ubuntu-latest # Change to windows-latest if needed
14+ runs-on : ubuntu-latest
1515
1616 steps :
1717 - name : Checkout Code
2020 - name : Setup .NET
2121 uses : actions/setup-dotnet@v3
2222 with :
23- dotnet-version : ' 8.0.406' # Use the correct .NET version for your project
23+ dotnet-version : ' 8.0.406'
2424
2525 - name : Restore Dependencies
2626 run : dotnet restore
@@ -30,19 +30,14 @@ jobs:
3030
3131 - name : Run Selenium Tests
3232 run : |
33- mkdir -p TestResults # Ensure the directory exists
33+ mkdir -p TestResults
3434 dotnet test --logger "trx;LogFileName=test-results.trx" --results-directory TestResults
3535
3636 - name : List Test Results Directory
37- run : ls -R TestResults # List contents of TestResults directory for debugging
37+ run : ls -R TestResults
3838
39- - name : Create a Release
40- id : create_release
41- uses : softprops/action-gh-release@v1
39+ - name : Upload Test Results as Artifact
40+ uses : actions/upload-artifact@v3
4241 with :
43- files : TestResults/* # Path to your test result files (could be modified if needed)
44-
45- - name : Upload Test Results as Release Asset
46- uses : softprops/action-gh-release@v1
47- with :
48- files : TestResults/*
42+ name : test-results
43+ path : TestResults/test-results.trx
You can’t perform that action at this time.
0 commit comments