Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 3 additions & 11 deletions .github/workflows/build-and-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ on:
branches: [master]
pull_request:
branches: [master]
workflow_dispatch:

jobs:
build:
Expand All @@ -17,24 +18,15 @@ jobs:
with:
dotnet-version: 8.0.x

- name: Restore projects
- name: Restore solution
run: dotnet restore projects/csharp/SqlRace.Examples.sln
env:
NUGET_AUTH_USERNAME: ${{ secrets.PACKAGES_USERNAME }}
NUGET_AUTH_TOKEN: ${{ secrets.PACKAGES_PATTOKEN }}

- name: Build projects
- name: Build solution
run: dotnet build projects/csharp/SqlRace.Examples.sln --no-restore --configuration Release

- name: Restore tests
run: dotnet restore tests/SqlRace.Examples.Tests/SqlRace.Examples.Tests.csproj
env:
NUGET_AUTH_USERNAME: ${{ secrets.PACKAGES_USERNAME }}
NUGET_AUTH_TOKEN: ${{ secrets.PACKAGES_PATTOKEN }}

- name: Build tests
run: dotnet build tests/SqlRace.Examples.Tests/SqlRace.Examples.Tests.csproj --no-restore --configuration Release

# NOTE: Tests are NOT executed in CI. Several tests initialise the SQL Race
# runtime via SqlRaceBootstrapper, which requires a SQL Race licence that the
# CI runner does not have (LicenceException). CI verifies compilation only;
Expand Down
24 changes: 23 additions & 1 deletion projects/csharp/SqlRace.Examples.sln
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.0.31903.59
Expand All @@ -19,6 +18,16 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "FunctionLibrary", "Function
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SessionCropper", "SessionCropper\SessionCropper.csproj", "{B8C9D0E1-F2A3-4567-BCDA-678901234567}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Tests", "Tests", "{02EA681E-C7D8-13C7-8484-4AC65E1B71E8}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Build", "Build", "{47352BB4-4B37-4719-8FE2-6F98EADFF975}"
ProjectSection(SolutionItems) = preProject
..\..\.github\workflows\build-and-test.yml = ..\..\.github\workflows\build-and-test.yml
..\..\.github\workflows\validate-notebooks.yml = ..\..\.github\workflows\validate-notebooks.yml
EndProjectSection
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SqlRace.Examples.Tests", "..\..\tests\SqlRace.Examples.Tests\SqlRace.Examples.Tests.csproj", "{B0C9821E-0AF8-F079-0168-06AA9E6B2A51}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand Down Expand Up @@ -57,5 +66,18 @@ Global
{B8C9D0E1-F2A3-4567-BCDA-678901234567}.Debug|Any CPU.Build.0 = Debug|Any CPU
{B8C9D0E1-F2A3-4567-BCDA-678901234567}.Release|Any CPU.ActiveCfg = Release|Any CPU
{B8C9D0E1-F2A3-4567-BCDA-678901234567}.Release|Any CPU.Build.0 = Release|Any CPU
{B0C9821E-0AF8-F079-0168-06AA9E6B2A51}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{B0C9821E-0AF8-F079-0168-06AA9E6B2A51}.Debug|Any CPU.Build.0 = Debug|Any CPU
{B0C9821E-0AF8-F079-0168-06AA9E6B2A51}.Release|Any CPU.ActiveCfg = Release|Any CPU
{B0C9821E-0AF8-F079-0168-06AA9E6B2A51}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(NestedProjects) = preSolution
{B0C9821E-0AF8-F079-0168-06AA9E6B2A51} = {02EA681E-C7D8-13C7-8484-4AC65E1B71E8}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {ADB34FDF-185F-4A40-817B-CE01EBE81EF9}
EndGlobalSection
EndGlobal
2 changes: 1 addition & 1 deletion tests/SqlRace.Examples.Tests/SqlRace.Examples.Tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.8.0" />
<PackageReference Include="xunit" Version="2.6.2" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.5.4" />
<PackageReference Include="Microsoft.CodeAnalysis.CSharp" Version="4.8.0" />
<PackageReference Include="Microsoft.CodeAnalysis.CSharp" Version="4.9.2" />
<PackageReference Include="MESL.SQLRace.API" Version="*" />
</ItemGroup>

Expand Down
Loading