Skip to content

Commit

Permalink
Add workflow job for checking library versions are compatible
Browse files Browse the repository at this point in the history
  • Loading branch information
gunndabad committed May 16, 2024
1 parent 79381e5 commit 305c01b
Show file tree
Hide file tree
Showing 3 changed files with 41 additions and 1 deletion.
30 changes: 29 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ on:

jobs:
build:

name: "Build & package"
runs-on: ubuntu-latest

Expand Down Expand Up @@ -56,3 +55,32 @@ jobs:
src/Dfe.Analytics.AspNetCore/bin/Release/*.nupkg
src/Dfe.Analytics.AspNetCore/bin/Release/*.snupkg
if-no-files-found: error

check_versions:
name: "Check library version compatibility"
runs-on: ubuntu-latest
needs: build

steps:
- uses: actions/checkout@v2

- run: |
mkdir app && cd app
mkdir lib
- name: Download Dfe.Analytics.Common.nupkg artifact
uses: actions/download-artifact@v2
with:
name: Dfe.Analytics.Common.nupkg
path: app/lib

- name: Download Dfe.Analytics.AspNetCore.nupkg artifact
uses: actions/download-artifact@v2
with:
name: Dfe.Analytics.AspNetCore.nupkg
path: app/lib

- run : |
cd app
dotnet new console
dotnet add package Dfe.Analytics.AspNetCore --source lib --prerelease
2 changes: 2 additions & 0 deletions s2/Program.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
// See https://aka.ms/new-console-template for more information
Console.WriteLine("Hello, World!");
10 changes: 10 additions & 0 deletions s2/s2.csproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net8.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
</PropertyGroup>

</Project>

0 comments on commit 305c01b

Please sign in to comment.