Skip to content

Commit

Permalink
Github workflows: codeql and unit tests run now on any PRs (#566)
Browse files Browse the repository at this point in the history
* Github workflows: codeql now also runs unit tests on PRs

Signed-off-by: Maximilien Noal <noal.maximilien@gmail.com>

* dependabot: fixed, doesn't work on sln files

Signed-off-by: Maximilien Noal <noal.maximilien@gmail.com>

---------

Signed-off-by: Maximilien Noal <noal.maximilien@gmail.com>
  • Loading branch information
maximilien-noal authored Jan 23, 2024
1 parent 3a18839 commit 3cccce2
Show file tree
Hide file tree
Showing 5 changed files with 50 additions and 11 deletions.
22 changes: 20 additions & 2 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,26 @@
version: 2
updates:
- package-ecosystem: "nuget"
directory: "/src"
directory: "/src/Spice86"
schedule:
interval: "weekly"
day: "wednesday"
open-pull-requests-limit: 8
open-pull-requests-limit: 5
- package-ecosystem: "nuget"
directory: "/src/Spice86.Core"
schedule:
interval: "weekly"
day: "wednesday"
open-pull-requests-limit: 5
- package-ecosystem: "nuget"
directory: "/src/Spice86.Logging"
schedule:
interval: "weekly"
day: "wednesday"
open-pull-requests-limit: 5
- package-ecosystem: "nuget"
directory: "/tests/Spice86.Tests"
schedule:
interval: "weekly"
day: "wednesday"
open-pull-requests-limit: 5
10 changes: 2 additions & 8 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,18 +12,12 @@
name: "CodeQL"

on:
push:
branches: [ "master" ]
pull_request:
# The branches below must be a subset of the branches above
branches: [ "master" ]
schedule:
- cron: '15 6 * * 4'
pull_request

jobs:
analyze:
name: Analyze
runs-on: ${{ (matrix.language == 'csharp' && 'macos-latest') || 'ubuntu-latest' }}
runs-on: 'ubuntu-latest'
permissions:
actions: read
contents: read
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: .NET Build
name: Test and Publish NuGet

# Trigger the workflow on push to master
on:
Expand Down
27 changes: 27 additions & 0 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Test and Publish NuGet

# Trigger the workflow on PRs
on:
pull_request

jobs:
build:

strategy:
matrix:
os: [macos-latest, windows-latest, ubuntu-latest]
fail-fast: false

runs-on: ${{ matrix.os }}

steps:
- uses: actions/checkout@v1

- name: Setup .NET
uses: actions/setup-dotnet@v1
with:
dotnet-version: '8.0.x'

- name: Test with dotnet
working-directory: ./src
run: dotnet test --configuration Release
File renamed without changes.

0 comments on commit 3cccce2

Please sign in to comment.