Skip to content

Commit

Permalink
add ci for build/test
Browse files Browse the repository at this point in the history
  • Loading branch information
kMutagene committed Apr 19, 2024
1 parent 9d3215b commit fad8e19
Show file tree
Hide file tree
Showing 2 changed files with 71 additions and 0 deletions.
66 changes: 66 additions & 0 deletions .github/workflows/build-and-test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
name: Build and test

on:
push:
branches: [ main ]
paths:
- 'src/**'
- 'tests/**'
- 'build/**'
- '.github/**'
pull_request:
branches: [ main ]
paths:
- 'src/**'
- 'tests/**'
- 'build/**'
- '.github/**'


jobs:

build-and-test-linux:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.x.x
- name: make script executable
run: chmod u+x build.sh
- name: Build and test
working-directory: ./
run: ./build.sh runtest

build-and-test-windows:

runs-on: windows-latest

steps:
- uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.x.x
- name: Build and test
working-directory: ./
run: ./build.cmd runtests

build-and-test-macos:

runs-on: macos-latest

steps:
- uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.x.x
- name: make script executable
run: chmod u+x build.sh
- name: Build and test
working-directory: ./
run: ./build.sh runtest
5 changes: 5 additions & 0 deletions FsLab.sln
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,11 @@ Project("{6EC3EE1D-3C4E-46DD-8F32-0CC8E7565705}") = "FsLab.Interactive.Tests", "
EndProject
Project("{6EC3EE1D-3C4E-46DD-8F32-0CC8E7565705}") = "FsLab.Tests", "tests\FsLab.Tests\FsLab.Tests.fsproj", "{5500FA1D-F562-44C4-A9E0-04EB22F8597B}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = ".ci", ".ci", "{9AD87CE9-074E-4D21-B35A-8A1B389B785D}"
ProjectSection(SolutionItems) = preProject
.github\workflows\build-and-test.yml = .github\workflows\build-and-test.yml
EndProjectSection
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand Down

0 comments on commit fad8e19

Please sign in to comment.