You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat: add workflows/README.md to elaborate on GitHub workflows (#210)
* feat: add workflows/README.md to elaborate on GitHub workflows
* feat: fix CI by upgrading Node version (#220)
* move most of the detail into the workflows
* Update .github/workflows/README.md
Co-authored-by: Luke Winship <luke.winship@gmail.com>
* Update .github/workflows/README.md
Co-authored-by: Luke Winship <luke.winship@gmail.com>
* Update .github/workflows/README.md
Co-authored-by: Luke Winship <luke.winship@gmail.com>
* Update .github/workflows/README.md
Co-authored-by: Luke Winship <luke.winship@gmail.com>
* review comments
* fix conflict
---------
Co-authored-by: Luke Winship <luke.winship@gmail.com>
This project contains two GitHub Action workflows that are performed following various triggers. For more information on Github Actions see [here](https://docs.github.com/en/actions).
3
+
4
+
## openactive-test-suite.yml
5
+
6
+
7
+
This workflow defines the following jobs:
8
+
-**test-server**
9
+
-**test-fake-database**
10
+
-**core**
11
+
-**framework**
12
+
-**deploy-reference-implementation**
13
+
-**publish-server**
14
+
-**publish-fake-database**
15
+
16
+
### test-server job
17
+
This job builds and runs the `OpenActive.Server.NET.Tests` project i.e. it runs unit tests against `OpenActive.Server.NET`.
18
+
19
+
### test-fake-database job
20
+
This job builds and runs the `Fakes/OpenActive.FakeDatabase.NET.Tests` project i.e. it runs unit tests against `Fakes/OpenActive.FakeDatabase.NET`.
21
+
22
+
### core job
23
+
This job uses Test Suite to run a matrix of tests against the `OpenActive.Server.NET` project.
24
+
25
+
### framework job
26
+
This job is very similar to the above but builds `OpenActive.Server.NET` using .NET Framework and runs Test Suite against it.
27
+
28
+
29
+
### deploy-reference-implementation job
30
+
This job deploys the `master` branch of Reference Implementation Booking Server ([see here](../../Examples/BookingSystem.AspNetCore/README.md)) and Identity Server Reference Implementation ([see here](../../Examples/BookingSystem.AspNetCore.IdentityServer/README.md)) to two Azure webapps
31
+
32
+
33
+
### publish-server job
34
+
This job publishes the OpenActive.Server.NET project to Nuget. It then creates a release in the GitHub repository.
35
+
36
+
37
+
### publish-fake-database job
38
+
Very similar to the above `publish-server` job, this job publishes the Fake Database project within OpenActive.Server.NET to Nuget.
39
+
40
+
## create-dependencies-pr.yaml
41
+
42
+
This workflow creates a pull request to OpenActive.Server.NET's OpenActive (OA) dependencies if there has been a change in one of those projects. This therefore keeps Server.NET up-to-date with the rest of the OA ecosystem.
43
+
44
+
This workflow can be triggered in two ways:
45
+
46
+
-**workflow_dispatch**: This allows you to manually trigger the workflow through the GitHub Actions UI.
47
+
48
+
-**repository_dispatch**: This allows the workflow to be triggered when a custom repository dispatch event is sent. It listens for dispatch events from two OA repos: `OpenActive.NET` and `OpenActive.DatasetSite.NET`. For more information on repository dispatch events [see here](https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows#repository_dispatch)
49
+
50
+
This workflow defines one job: **generate**.
51
+
52
+
### generate job
53
+
The main steps of this job are as follows:
54
+
-**Update OpenActive.NET to latest version in OpenActive.Server.NET**: This step updates the Server.NET solution with the latest OpenActive.NET library.
55
+
56
+
-**Update OpenActive.DatasetSite.NET to latest version in OpenActive.Server.NET**: Similar to the previous step, this updates Server.NET with the latest OpenActive.DatasetSite.NET.
57
+
58
+
-**Update OpenActive.NET to latest version in OpenActive.FakeDatabase.NET**: Similar to the previous step, this updates FakeDatabase.NET with the latest OpenActive.NET.
59
+
60
+
-**Create Pull Request**: This step uses the peter-evans/create-pull-request action to create a pull request. It performs several actions which are relatively self explanatory:
61
+
62
+
- Sets up the access token needed for making changes to the repository.
63
+
- Specifies the path to the repository containing the changes.
64
+
- Defines a commit message, committer, author, branch name, and other PR-related details.
65
+
- Provides a title and body for the pull request, explaining the purpose of the update.
66
+
- Adds labels to the pull request (`automated pr`).
67
+
- Marks the pull request as not a draft.
68
+
69
+
-**Check outputs** prints information about the created pull request, including the pull request number and URL, to the console.
# Runs the tests for the "OpenActive.FakeDatabase.NET.Tests" project using the `dotnet test` command. It runs the
53
+
# unit tests and uses the `--configuration Release` flag for release mode, `--no-build` to skip rebuilding the
54
+
# project since it was built in the previous step, and `--verbosity normal` for the level of detail in the test
55
+
# output
34
56
- name: Run OpenActive.FakeDatabase.NET.Tests
35
57
run: dotnet test ./Fakes/OpenActive.FakeDatabase.NET.Tests/OpenActive.FakeDatabase.NET.Tests.csproj --configuration Release --no-build --verbosity normal
36
58
37
59
core:
60
+
# Specifies that this job depends on the successful completion of two other jobs: "test-server" and "test-fake-database"
38
61
needs:
39
62
- test-server
40
63
- test-fake-database
41
64
runs-on: ubuntu-latest
65
+
66
+
# Defines a matrix strategy for running tests with different combinations of parameters, allowing for parallel test
67
+
# runs with various configurations. For more information about these parameters, see `.github/README.md` in Test
0 commit comments