From 966a82c4fcb96b4b35a855e0f18d557ab7fd18ee Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Sun, 25 Aug 2024 23:13:21 +0200 Subject: [PATCH 01/39] build + test --- .gitea/workflows/Quality.yaml | 36 +++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 .gitea/workflows/Quality.yaml diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml new file mode 100644 index 0000000..9782d45 --- /dev/null +++ b/.gitea/workflows/Quality.yaml @@ -0,0 +1,36 @@ +name: "Main Build Process" + +# Runs on main branch commits, +# every commit in a pull request, any published release. +on: + push: + branches: ["main"] + pull_request: + branches: ["main"] + release: + types: [published] + +env: + REGISTRY: gitea.borealian.ovh + IMAGE_NAME: ${{ github.repository }} +jobs: + build: + name: "Build & Test" + + # Permissions this GitHub Action needs for other things in GitHub + permissions: write-all + + runs-on: ubuntu-latest + + steps: + - name: Check out the code + uses: actions/checkout@v4 + with: + fetch-depth: 0 + - name: Setup .NET + uses: actions/setup-dotnet@v4 + with: + dotnet-version: | + 8.x + - name: "Restore/Build/Test" + run: dotnet test --configuration Release --verbosity normal --logger trx --collect:"XPlat Code Coverage" -- 2.49.1 From f7eb584b913a2aa379ee36fdfc7027ad41975d49 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Sun, 25 Aug 2024 23:18:35 +0200 Subject: [PATCH 02/39] suite --- .gitea/workflows/Quality.yaml | 52 ++++++++++++++++++++++++++++++++++- 1 file changed, 51 insertions(+), 1 deletion(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index 9782d45..d14cc28 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -33,4 +33,54 @@ jobs: dotnet-version: | 8.x - name: "Restore/Build/Test" - run: dotnet test --configuration Release --verbosity normal --logger trx --collect:"XPlat Code Coverage" + run: dotnet test ./src/LittleTown.sln --configuration Release --verbosity normal --logger trx --collect:"XPlat Code Coverage" + - name: Combine Coverage Reports # This is because one report is produced per project, and we want one result for all of them. + uses: danielpalme/ReportGenerator-GitHub-Action@5.3.8 + with: + reports: "**/*.cobertura.xml" # REQUIRED # The coverage reports that should be parsed (separated by semicolon). Globbing is supported. + targetdir: "${{ github.workspace }}" # REQUIRED # The directory where the generated report should be saved. + reporttypes: "Cobertura" # The output formats and scope (separated by semicolon) Values: Badges, Clover, Cobertura, CsvSummary, Html, Html_Dark, Html_Light, Html_BlueRed, HtmlChart, HtmlInline, HtmlInline_AzurePipelines, HtmlInline_AzurePipelines_Dark, HtmlInline_AzurePipelines_Light, HtmlSummary, JsonSummary, Latex, LatexSummary, lcov, MarkdownSummary, MarkdownSummaryGithub, MarkdownDeltaSummary, MHtml, PngChart, SonarQube, TeamCitySummary, TextSummary, TextDeltaSummary, Xml, XmlSummary + verbosity: "Info" # The verbosity level of the log messages. Values: Verbose, Info, Warning, Error, Off + title: "Code Coverage" # Optional title. + tag: "${{ github.run_number }}_${{ github.run_id }}" # Optional tag or build version. + customSettings: "" # Optional custom settings (separated by semicolon). See: https://github.com/danielpalme/ReportGenerator/wiki/Settings. + toolpath: "reportgeneratortool" # Default directory for installing the dotnet tool. + - name: Upload Combined Coverage XML + uses: actions/upload-artifact@v4 + with: + name: coverage + path: ${{ github.workspace }}/Cobertura.xml + retention-days: 5 + - name: Publish Code Coverage Report + uses: irongut/CodeCoverageSummary@v1.3.0 + with: + filename: "Cobertura.xml" + badge: true + fail_below_min: false # just informative for now + format: markdown + hide_branch_rate: false + hide_complexity: false + indicators: true + output: both + thresholds: "10 30" + + - name: Add Coverage PR Comment + uses: marocchino/sticky-pull-request-comment@v2 + if: github.event_name == 'pull_request' + with: + recreate: true + path: code-coverage-results.md + + - name: Upload Test Result Files + uses: actions/upload-artifact@v4 + with: + name: test-results + path: ${{ github.workspace }}/**/TestResults/**/* + retention-days: 5 + + - name: Publish Test Results + uses: EnricoMi/publish-unit-test-result-action@v2.16.1 + if: always() + with: + # NOTE: using trx_files instead of files due to https://github.com/EnricoMi/publish-unit-test-result-action/issues/424 + trx_files: "${{ github.workspace }}/**/*.trx" \ No newline at end of file -- 2.49.1 From cdeab78d432d7124b34a0c25cec036ca736fda3b Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Sun, 25 Aug 2024 23:24:17 +0200 Subject: [PATCH 03/39] suite --- .gitea/workflows/Quality.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index d14cc28..3303d45 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -23,6 +23,8 @@ jobs: runs-on: ubuntu-latest steps: + - run: echo "🎉 The job was automatically triggered by a ${{ github.repository }} event." + - name: Check out the code uses: actions/checkout@v4 with: -- 2.49.1 From 582759b31e2354ddca8d0686cf07219a7f5cc932 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Sun, 25 Aug 2024 23:31:42 +0200 Subject: [PATCH 04/39] suite --- .gitea/workflows/Quality.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index 3303d45..22b4d80 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -48,7 +48,7 @@ jobs: customSettings: "" # Optional custom settings (separated by semicolon). See: https://github.com/danielpalme/ReportGenerator/wiki/Settings. toolpath: "reportgeneratortool" # Default directory for installing the dotnet tool. - name: Upload Combined Coverage XML - uses: actions/upload-artifact@v4 + uses: actions/upload-artifact@v3 with: name: coverage path: ${{ github.workspace }}/Cobertura.xml -- 2.49.1 From a0ef7be672db987dd03f6714f9ddbdeb2d05be8a Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Sun, 25 Aug 2024 23:50:31 +0200 Subject: [PATCH 05/39] suite --- .gitea/workflows/Quality.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index 22b4d80..ca34032 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -23,7 +23,7 @@ jobs: runs-on: ubuntu-latest steps: - - run: echo "🎉 The job was automatically triggered by a ${{ github.repository }} event." + - run: echo "🎉 The job was automatically triggered by a ${{ github.event_name }} event." - name: Check out the code uses: actions/checkout@v4 -- 2.49.1 From f232126f0db1e020ef3c19066fe5cc680df2e4c4 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Sun, 25 Aug 2024 23:56:46 +0200 Subject: [PATCH 06/39] suite --- .gitea/workflows/Quality.yaml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index ca34032..c1686ab 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -18,7 +18,8 @@ jobs: name: "Build & Test" # Permissions this GitHub Action needs for other things in GitHub - permissions: write-all + permissions: + pull-requests: write runs-on: ubuntu-latest @@ -53,6 +54,7 @@ jobs: name: coverage path: ${{ github.workspace }}/Cobertura.xml retention-days: 5 + - run: ls - name: Publish Code Coverage Report uses: irongut/CodeCoverageSummary@v1.3.0 with: @@ -70,8 +72,8 @@ jobs: uses: marocchino/sticky-pull-request-comment@v2 if: github.event_name == 'pull_request' with: - recreate: true - path: code-coverage-results.md + message: | + Release ${{ github.sha }} to - name: Upload Test Result Files uses: actions/upload-artifact@v4 -- 2.49.1 From 8f9eefdedf024ea6d7da3b580267fbf4296dd592 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 00:02:55 +0200 Subject: [PATCH 07/39] suite --- .gitea/workflows/Quality.yaml | 7 +++--- .gitea/workflows/tests.yaml | 40 +++++++++++++++++------------------ 2 files changed, 23 insertions(+), 24 deletions(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index c1686ab..ebaec7b 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -54,7 +54,6 @@ jobs: name: coverage path: ${{ github.workspace }}/Cobertura.xml retention-days: 5 - - run: ls - name: Publish Code Coverage Report uses: irongut/CodeCoverageSummary@v1.3.0 with: @@ -67,13 +66,13 @@ jobs: indicators: true output: both thresholds: "10 30" - + - run: ls - name: Add Coverage PR Comment uses: marocchino/sticky-pull-request-comment@v2 if: github.event_name == 'pull_request' with: - message: | - Release ${{ github.sha }} to + recreate: true + path: code-coverage-results.md - name: Upload Test Result Files uses: actions/upload-artifact@v4 diff --git a/.gitea/workflows/tests.yaml b/.gitea/workflows/tests.yaml index df42205..874fa2b 100644 --- a/.gitea/workflows/tests.yaml +++ b/.gitea/workflows/tests.yaml @@ -1,24 +1,24 @@ -name: dotnet package +# name: dotnet package -on: [push] +# on: [push] -jobs: - build: +# jobs: +# build: - runs-on: ubuntu-latest - strategy: - matrix: - dotnet-version: [ '8.0.x' ] +# runs-on: ubuntu-latest +# strategy: +# matrix: +# dotnet-version: [ '8.0.x' ] - steps: - - uses: actions/checkout@v4 - - name: Setup dotnet - uses: actions/setup-dotnet@v3 - with: - dotnet-version: '8.0.x' - - name: Install dependencies - run: dotnet restore ./src/LittleTown.sln - - name: Build - run: dotnet build ./src/LittleTown.sln - - name: Test with the dotnet CLI - run: dotnet test ./src/LittleTown.sln \ No newline at end of file +# steps: +# - uses: actions/checkout@v4 +# - name: Setup dotnet +# uses: actions/setup-dotnet@v3 +# with: +# dotnet-version: '8.0.x' +# - name: Install dependencies +# run: dotnet restore ./src/LittleTown.sln +# - name: Build +# run: dotnet build ./src/LittleTown.sln +# - name: Test with the dotnet CLI +# run: dotnet test ./src/LittleTown.sln \ No newline at end of file -- 2.49.1 From 633801c8a427eafc59c7150121bc4700979b1c81 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 00:16:42 +0200 Subject: [PATCH 08/39] suite --- .gitea/workflows/Quality.yaml | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index ebaec7b..c6d4a07 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -18,8 +18,7 @@ jobs: name: "Build & Test" # Permissions this GitHub Action needs for other things in GitHub - permissions: - pull-requests: write + permissions: write-all runs-on: ubuntu-latest @@ -66,14 +65,6 @@ jobs: indicators: true output: both thresholds: "10 30" - - run: ls - - name: Add Coverage PR Comment - uses: marocchino/sticky-pull-request-comment@v2 - if: github.event_name == 'pull_request' - with: - recreate: true - path: code-coverage-results.md - - name: Upload Test Result Files uses: actions/upload-artifact@v4 with: -- 2.49.1 From 73256fcba91236f2ab7242bb5d23fe1fbfe8d095 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 00:18:50 +0200 Subject: [PATCH 09/39] suite --- .gitea/workflows/Quality.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index c6d4a07..b5cc082 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -66,7 +66,7 @@ jobs: output: both thresholds: "10 30" - name: Upload Test Result Files - uses: actions/upload-artifact@v4 + uses: actions/upload-artifact@v3 with: name: test-results path: ${{ github.workspace }}/**/TestResults/**/* -- 2.49.1 From 3d7e6f09701defdeb902c548b7bd9023f1c651ce Mon Sep 17 00:00:00 2001 From: Andre Plourde Date: Mon, 26 Aug 2024 14:23:31 +0200 Subject: [PATCH 10/39] suite2 --- .gitea/workflows/Quality.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index b5cc082..eb00649 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -73,7 +73,7 @@ jobs: retention-days: 5 - name: Publish Test Results - uses: EnricoMi/publish-unit-test-result-action@v2.16.1 + uses: EnricoMi/publish-unit-test-result-action/linux@v2 if: always() with: # NOTE: using trx_files instead of files due to https://github.com/EnricoMi/publish-unit-test-result-action/issues/424 -- 2.49.1 From 94100940c2107477d94046e23913414ca0a175db Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 14:39:51 +0200 Subject: [PATCH 11/39] suite2 --- .gitea/workflows/Quality.yaml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index eb00649..b4eddfe 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -65,6 +65,12 @@ jobs: indicators: true output: both thresholds: "10 30" + - name: Add Coverage PR Comment + uses: marocchino/sticky-pull-request-comment@v1 + if: github.event_name == 'pull_request' + with: + recreate: true + path: code-coverage-results.md - name: Upload Test Result Files uses: actions/upload-artifact@v3 with: -- 2.49.1 From f8a20643c61997ff948d32ba32931d01bb87a3dc Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 14:43:21 +0200 Subject: [PATCH 12/39] suite2 --- .gitea/workflows/Quality.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index b4eddfe..03345f6 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -66,7 +66,7 @@ jobs: output: both thresholds: "10 30" - name: Add Coverage PR Comment - uses: marocchino/sticky-pull-request-comment@v1 + uses: marocchino/sticky-pull-request-comment@v2.9 if: github.event_name == 'pull_request' with: recreate: true -- 2.49.1 From d109ac85324608cc00b10fc2ee644da48909d6d1 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 14:59:51 +0200 Subject: [PATCH 13/39] suite2 --- .gitea/workflows/Quality.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index 03345f6..da18358 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -66,7 +66,7 @@ jobs: output: both thresholds: "10 30" - name: Add Coverage PR Comment - uses: marocchino/sticky-pull-request-comment@v2.9 + uses: marocchino/sticky-pull-request-comment@v2 if: github.event_name == 'pull_request' with: recreate: true -- 2.49.1 From 59cbfa4738f3680c87dd1ea4812b047359ab0ec9 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 15:29:03 +0200 Subject: [PATCH 14/39] suite2 --- .gitea/workflows/Quality.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index da18358..53aa823 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -66,7 +66,7 @@ jobs: output: both thresholds: "10 30" - name: Add Coverage PR Comment - uses: marocchino/sticky-pull-request-comment@v2 + uses: marocchino/sticky-pull-request-comment@v2.6.2 if: github.event_name == 'pull_request' with: recreate: true @@ -74,6 +74,7 @@ jobs: - name: Upload Test Result Files uses: actions/upload-artifact@v3 with: + name: test-results name: test-results path: ${{ github.workspace }}/**/TestResults/**/* retention-days: 5 -- 2.49.1 From 8b7a2559a7f17bb027ff408aa186a924ef8fe224 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 15:32:22 +0200 Subject: [PATCH 15/39] suite2 --- .gitea/workflows/Quality.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index 53aa823..bb5872f 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -66,7 +66,7 @@ jobs: output: both thresholds: "10 30" - name: Add Coverage PR Comment - uses: marocchino/sticky-pull-request-comment@v2.6.2 + uses: marocchino/sticky-pull-request-comment@v2 if: github.event_name == 'pull_request' with: recreate: true -- 2.49.1 From 069360992c99fe9823fb2785470085cf5c21a575 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 15:35:17 +0200 Subject: [PATCH 16/39] suite3 --- .gitea/workflows/Quality.yaml | 1 - .gitea/workflows/tests.yaml | 40 +++++++++++++++++------------------ 2 files changed, 20 insertions(+), 21 deletions(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index bb5872f..da18358 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -74,7 +74,6 @@ jobs: - name: Upload Test Result Files uses: actions/upload-artifact@v3 with: - name: test-results name: test-results path: ${{ github.workspace }}/**/TestResults/**/* retention-days: 5 diff --git a/.gitea/workflows/tests.yaml b/.gitea/workflows/tests.yaml index 874fa2b..df42205 100644 --- a/.gitea/workflows/tests.yaml +++ b/.gitea/workflows/tests.yaml @@ -1,24 +1,24 @@ -# name: dotnet package +name: dotnet package -# on: [push] +on: [push] -# jobs: -# build: +jobs: + build: -# runs-on: ubuntu-latest -# strategy: -# matrix: -# dotnet-version: [ '8.0.x' ] + runs-on: ubuntu-latest + strategy: + matrix: + dotnet-version: [ '8.0.x' ] -# steps: -# - uses: actions/checkout@v4 -# - name: Setup dotnet -# uses: actions/setup-dotnet@v3 -# with: -# dotnet-version: '8.0.x' -# - name: Install dependencies -# run: dotnet restore ./src/LittleTown.sln -# - name: Build -# run: dotnet build ./src/LittleTown.sln -# - name: Test with the dotnet CLI -# run: dotnet test ./src/LittleTown.sln \ No newline at end of file + steps: + - uses: actions/checkout@v4 + - name: Setup dotnet + uses: actions/setup-dotnet@v3 + with: + dotnet-version: '8.0.x' + - name: Install dependencies + run: dotnet restore ./src/LittleTown.sln + - name: Build + run: dotnet build ./src/LittleTown.sln + - name: Test with the dotnet CLI + run: dotnet test ./src/LittleTown.sln \ No newline at end of file -- 2.49.1 From 857a618e40abc58287151a8aaf175ba29e12cb8a Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 15:47:02 +0200 Subject: [PATCH 17/39] suite3 --- .gitea/workflows/Quality.yaml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index da18358..3b80c24 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -69,8 +69,9 @@ jobs: uses: marocchino/sticky-pull-request-comment@v2 if: github.event_name == 'pull_request' with: - recreate: true - path: code-coverage-results.md + message: | + Release ${{ github.sha }} + - name: Upload Test Result Files uses: actions/upload-artifact@v3 with: -- 2.49.1 From 097b7e434096f64ef9b73b1542b48db5d1493fe6 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 15:55:00 +0200 Subject: [PATCH 18/39] suite3 --- .gitea/workflows/Quality.yaml | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index 3b80c24..b275198 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -23,8 +23,6 @@ jobs: runs-on: ubuntu-latest steps: - - run: echo "🎉 The job was automatically triggered by a ${{ github.event_name }} event." - - name: Check out the code uses: actions/checkout@v4 with: @@ -71,7 +69,21 @@ jobs: with: message: | Release ${{ github.sha }} - + + - name: Comment on Gitea PR + env: + GITEA_TOKEN: ${{ secrets.GITEA_TOKEN }} + GITEA_URL: https://gitea.borealian.ovh + REPO_OWNER: mcmuzzle + REPO_NAME: LittleTown + PR_NUMBER: ${{ github.event.pull_request.number }} + run: | + curl -X POST \ + -H "Authorization: token ${GITEA_TOKEN}" \ + -H "Content-Type: application/json" \ + -d '{"body": "Merci pour votre contribution !"}' \ + ${GITEA_URL}/api/v1/repos/${REPO_OWNER}/${REPO_NAME}/issues/${PR_NUMBER}/comments + - name: Upload Test Result Files uses: actions/upload-artifact@v3 with: -- 2.49.1 From 8e6262d4d58d229ae723b02988c5128b66bc5829 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 16:03:48 +0200 Subject: [PATCH 19/39] suite3 --- .gitea/workflows/Quality.yaml | 7 ------- 1 file changed, 7 deletions(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index b275198..a968c0d 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -63,13 +63,6 @@ jobs: indicators: true output: both thresholds: "10 30" - - name: Add Coverage PR Comment - uses: marocchino/sticky-pull-request-comment@v2 - if: github.event_name == 'pull_request' - with: - message: | - Release ${{ github.sha }} - - name: Comment on Gitea PR env: GITEA_TOKEN: ${{ secrets.GITEA_TOKEN }} -- 2.49.1 From 96bc3c546a2f48564ac17295421ecca4fca1a11b Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 16:29:17 +0200 Subject: [PATCH 20/39] suite3 --- .gitea/workflows/Quality.yaml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index a968c0d..a3ed490 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -70,11 +70,13 @@ jobs: REPO_OWNER: mcmuzzle REPO_NAME: LittleTown PR_NUMBER: ${{ github.event.pull_request.number }} + run: | + COMMENT_CONTENT=$(cat code-coverage-results.md) curl -X POST \ -H "Authorization: token ${GITEA_TOKEN}" \ -H "Content-Type: application/json" \ - -d '{"body": "Merci pour votre contribution !"}' \ + -d "{\"body\": \"${COMMENT_CONTENT}\"}" \ ${GITEA_URL}/api/v1/repos/${REPO_OWNER}/${REPO_NAME}/issues/${PR_NUMBER}/comments - name: Upload Test Result Files -- 2.49.1 From 85b12b1d4bf1a6c41f3f02df04a92f58325db56e Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 16:43:06 +0200 Subject: [PATCH 21/39] suite3 --- .gitea/workflows/Quality.yaml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index a3ed490..8cbaaa7 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -87,8 +87,10 @@ jobs: retention-days: 5 - name: Publish Test Results - uses: EnricoMi/publish-unit-test-result-action/linux@v2 + uses: EnricoMi/publish-unit-test-result-action@v2 if: always() with: - # NOTE: using trx_files instead of files due to https://github.com/EnricoMi/publish-unit-test-result-action/issues/424 - trx_files: "${{ github.workspace }}/**/*.trx" \ No newline at end of file + files: | + test-results/**/*.xml + test-results/**/*.trx + test-results/**/*.json -- 2.49.1 From 2450e4370ca7588be0358f497daafcced56a4de4 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 16:48:43 +0200 Subject: [PATCH 22/39] suite3 --- .gitea/workflows/Quality.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index 8cbaaa7..087960d 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -91,6 +91,6 @@ jobs: if: always() with: files: | - test-results/**/*.xml - test-results/**/*.trx - test-results/**/*.json + TestResults/**/*.xml + TestResults/**/*.trx + TestResults/**/*.json -- 2.49.1 From 218e7ea9af0895a262a9c65345ddec5c485dd456 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 21:31:52 +0200 Subject: [PATCH 23/39] suite4 --- .gitea/workflows/Quality.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index 087960d..c83f874 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -78,7 +78,7 @@ jobs: -H "Content-Type: application/json" \ -d "{\"body\": \"${COMMENT_CONTENT}\"}" \ ${GITEA_URL}/api/v1/repos/${REPO_OWNER}/${REPO_NAME}/issues/${PR_NUMBER}/comments - + - name: Upload Test Result Files uses: actions/upload-artifact@v3 with: @@ -91,6 +91,6 @@ jobs: if: always() with: files: | - TestResults/**/*.xml - TestResults/**/*.trx - TestResults/**/*.json + **/TestResults/**/*.xml + **/TestResults/**/*.trx + **/TestResults/**/*.json -- 2.49.1 From afac94fc71924e05f7adfd70f9dd066121c26847 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 21:40:28 +0200 Subject: [PATCH 24/39] suite4 --- .gitea/workflows/Quality.yaml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index c83f874..22dd053 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -91,6 +91,4 @@ jobs: if: always() with: files: | - **/TestResults/**/*.xml **/TestResults/**/*.trx - **/TestResults/**/*.json -- 2.49.1 From c8f34c9fcd6f9860ddadb3050cbe0f00cc6ed0bf Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 21:55:27 +0200 Subject: [PATCH 25/39] suite4 --- .gitea/workflows/Quality.yaml | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index 22dd053..ac11ea9 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -86,9 +86,16 @@ jobs: path: ${{ github.workspace }}/**/TestResults/**/* retention-days: 5 - - name: Publish Test Results - uses: EnricoMi/publish-unit-test-result-action@v2 - if: always() - with: - files: | - **/TestResults/**/*.trx + - name: test + image: mcr.microsoft.com/dotnet/sdk:7.0 + commands: + - dotnet test --logger:"trx;LogFileName=test_results.xml" + - report-tool publish test_results.xml + + - name: publish-comment + image: curlimages/curl + environment: + GITEA_TOKEN: ${{ secrets.GITEA_TOKEN }} + commands: + - COMMENT="Test Results: $(cat test_results.xml)" + - curl -X POST -H "Authorization: token ${GITEA_TOKEN}" -d "{ \"body\": \"$COMMENT\" }" "${DRONE_BUILD_LINK}/comments" -- 2.49.1 From 00288f275f5cb3e78f9e0e6b0df911c9e897eecd Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 21:58:09 +0200 Subject: [PATCH 26/39] suite4 --- .gitea/workflows/Quality.yaml | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index ac11ea9..a87d0df 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -33,7 +33,7 @@ jobs: dotnet-version: | 8.x - name: "Restore/Build/Test" - run: dotnet test ./src/LittleTown.sln --configuration Release --verbosity normal --logger trx --collect:"XPlat Code Coverage" + run: dotnet test ./src/LittleTown.sln --configuration Release --verbosity normal --logger trx --collect:"XPlat Code Coverage" --logger:"trx;LogFileName=test_results.xml" - name: Combine Coverage Reports # This is because one report is produced per project, and we want one result for all of them. uses: danielpalme/ReportGenerator-GitHub-Action@5.3.8 with: @@ -86,12 +86,6 @@ jobs: path: ${{ github.workspace }}/**/TestResults/**/* retention-days: 5 - - name: test - image: mcr.microsoft.com/dotnet/sdk:7.0 - commands: - - dotnet test --logger:"trx;LogFileName=test_results.xml" - - report-tool publish test_results.xml - - name: publish-comment image: curlimages/curl environment: -- 2.49.1 From 9f7333c8a49cde4f7f29da053c53e8d37c57f728 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 22:00:13 +0200 Subject: [PATCH 27/39] suite4 --- .gitea/workflows/Quality.yaml | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index a87d0df..290ba65 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -33,7 +33,8 @@ jobs: dotnet-version: | 8.x - name: "Restore/Build/Test" - run: dotnet test ./src/LittleTown.sln --configuration Release --verbosity normal --logger trx --collect:"XPlat Code Coverage" --logger:"trx;LogFileName=test_results.xml" + run: | + dotnet test ./src/LittleTown.sln --configuration Release --verbosity normal --logger trx --collect:"XPlat Code Coverage" --logger:"trx;LogFileName=test_results.xml" - name: Combine Coverage Reports # This is because one report is produced per project, and we want one result for all of them. uses: danielpalme/ReportGenerator-GitHub-Action@5.3.8 with: @@ -85,11 +86,3 @@ jobs: name: test-results path: ${{ github.workspace }}/**/TestResults/**/* retention-days: 5 - - - name: publish-comment - image: curlimages/curl - environment: - GITEA_TOKEN: ${{ secrets.GITEA_TOKEN }} - commands: - - COMMENT="Test Results: $(cat test_results.xml)" - - curl -X POST -H "Authorization: token ${GITEA_TOKEN}" -d "{ \"body\": \"$COMMENT\" }" "${DRONE_BUILD_LINK}/comments" -- 2.49.1 From dd38a0f22d2e9aac1769c870382d979ea1a631b8 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 22:07:59 +0200 Subject: [PATCH 28/39] suite4 --- .gitea/workflows/Quality.yaml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index 290ba65..05f5654 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -86,3 +86,6 @@ jobs: name: test-results path: ${{ github.workspace }}/**/TestResults/**/* retention-days: 5 + - name: debug + run : ls + -- 2.49.1 From 646d6b7ab78053d1134f4e999db18665bdfcb078 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 22:13:11 +0200 Subject: [PATCH 29/39] suite4 --- .gitea/workflows/Quality.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index 05f5654..cf7a887 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -35,6 +35,7 @@ jobs: - name: "Restore/Build/Test" run: | dotnet test ./src/LittleTown.sln --configuration Release --verbosity normal --logger trx --collect:"XPlat Code Coverage" --logger:"trx;LogFileName=test_results.xml" + report-tool publish test_results.xml - name: Combine Coverage Reports # This is because one report is produced per project, and we want one result for all of them. uses: danielpalme/ReportGenerator-GitHub-Action@5.3.8 with: -- 2.49.1 From e3b62eed145401c33d67dc8554a98ffddeaf79f5 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 22:23:28 +0200 Subject: [PATCH 30/39] suite5 --- .gitea/workflows/Quality.yaml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index cf7a887..a6b7827 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -34,8 +34,9 @@ jobs: 8.x - name: "Restore/Build/Test" run: | - dotnet test ./src/LittleTown.sln --configuration Release --verbosity normal --logger trx --collect:"XPlat Code Coverage" --logger:"trx;LogFileName=test_results.xml" - report-tool publish test_results.xml + dotnet test ./src/LittleTown.sln --configuration Release --verbosity normal --logger "nunit;LogFileName=TestResults.xml" + dotnet tool install -g dotnet-reportgenerator-globaltool + reportgenerator "-reports:TestResults.xml" "-targetdir:./report" "-reporttypes:Html" - name: Combine Coverage Reports # This is because one report is produced per project, and we want one result for all of them. uses: danielpalme/ReportGenerator-GitHub-Action@5.3.8 with: -- 2.49.1 From 9cc5e31ba190e121f61278c7da44a101fedacc57 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 22:31:45 +0200 Subject: [PATCH 31/39] suite5 --- .gitea/workflows/Quality.yaml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index a6b7827..cb9bcca 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -35,8 +35,6 @@ jobs: - name: "Restore/Build/Test" run: | dotnet test ./src/LittleTown.sln --configuration Release --verbosity normal --logger "nunit;LogFileName=TestResults.xml" - dotnet tool install -g dotnet-reportgenerator-globaltool - reportgenerator "-reports:TestResults.xml" "-targetdir:./report" "-reporttypes:Html" - name: Combine Coverage Reports # This is because one report is produced per project, and we want one result for all of them. uses: danielpalme/ReportGenerator-GitHub-Action@5.3.8 with: -- 2.49.1 From a57e0e09246bfb9bba129033a169e9b40a388a62 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 22:58:10 +0200 Subject: [PATCH 32/39] suite6 --- .gitea/workflows/Quality.yaml | 2 +- .../LittleTown.Core.Tests.csproj | 1 + .../TestResults/TestResults.trx | 62 +++++++++++++++++++ 3 files changed, 64 insertions(+), 1 deletion(-) create mode 100644 src/LittleTown.Core.Tests/TestResults/TestResults.trx diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index cb9bcca..09f9f68 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -34,7 +34,7 @@ jobs: 8.x - name: "Restore/Build/Test" run: | - dotnet test ./src/LittleTown.sln --configuration Release --verbosity normal --logger "nunit;LogFileName=TestResults.xml" + dotnet test ./src/LittleTown.sln --configuration Release --logger "trx;LogFileName=TestResults.trx" - name: Combine Coverage Reports # This is because one report is produced per project, and we want one result for all of them. uses: danielpalme/ReportGenerator-GitHub-Action@5.3.8 with: diff --git a/src/LittleTown.Core.Tests/LittleTown.Core.Tests.csproj b/src/LittleTown.Core.Tests/LittleTown.Core.Tests.csproj index 0ca78a7..4ffeaf3 100644 --- a/src/LittleTown.Core.Tests/LittleTown.Core.Tests.csproj +++ b/src/LittleTown.Core.Tests/LittleTown.Core.Tests.csproj @@ -12,6 +12,7 @@ + runtime; build; native; contentfiles; analyzers; buildtransitive diff --git a/src/LittleTown.Core.Tests/TestResults/TestResults.trx b/src/LittleTown.Core.Tests/TestResults/TestResults.trx new file mode 100644 index 0000000..58ac072 --- /dev/null +++ b/src/LittleTown.Core.Tests/TestResults/TestResults.trx @@ -0,0 +1,62 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + NUnit Adapter 4.6.0.0: Test execution started +Running all tests in D:\Sandbox\projets\LittleTown\src\LittleTown.Core.Tests\bin\Debug\net8.0\LittleTown.Core.Tests.dll + NUnit3TestExecutor discovered 0 of 0 NUnit test cases using Current Discovery mode, Explicit run +NUnit Adapter 4.6.0.0: Test execution complete +[xUnit.net 00:00:00.00] xUnit.net VSTest Adapter v2.4.5+1caef2f33e (64-bit .NET 8.0.1) +[xUnit.net 00:00:00.31] Discovering: LittleTown.Core.Tests +[xUnit.net 00:00:00.33] Discovered: LittleTown.Core.Tests +[xUnit.net 00:00:00.33] Starting: LittleTown.Core.Tests +[xUnit.net 00:00:00.43] Finished: LittleTown.Core.Tests + + + + \ No newline at end of file -- 2.49.1 From 6e38a4ae4983a1d694d4f1b74255b362822f4b1e Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 23:01:59 +0200 Subject: [PATCH 33/39] suite6 --- .gitea/workflows/Quality.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index 09f9f68..d87e952 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -34,7 +34,7 @@ jobs: 8.x - name: "Restore/Build/Test" run: | - dotnet test ./src/LittleTown.sln --configuration Release --logger "trx;LogFileName=TestResults.trx" + dotnet test ./src/LittleTown.sln --configuration Release --logger "trx;LogFileName=TestResults.trx" --collect:"XPlat Code Coverage" - name: Combine Coverage Reports # This is because one report is produced per project, and we want one result for all of them. uses: danielpalme/ReportGenerator-GitHub-Action@5.3.8 with: -- 2.49.1 From 9729989ee629e7f7009894cd48ec6e3a70d6c10f Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 23:34:44 +0200 Subject: [PATCH 34/39] suite7 --- .gitea/workflows/Quality.yaml | 2 + .../TestResults/TestResults.trx | 62 ------------------- 2 files changed, 2 insertions(+), 62 deletions(-) delete mode 100644 src/LittleTown.Core.Tests/TestResults/TestResults.trx diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index d87e952..fa453b9 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -35,6 +35,8 @@ jobs: - name: "Restore/Build/Test" run: | dotnet test ./src/LittleTown.sln --configuration Release --logger "trx;LogFileName=TestResults.trx" --collect:"XPlat Code Coverage" + dotnet tool install -g dotnet-reportgenerator-globaltool + reportgenerator "-reports:TestResults.trx" "-targetdir:./report" "-reporttypes:Html" - name: Combine Coverage Reports # This is because one report is produced per project, and we want one result for all of them. uses: danielpalme/ReportGenerator-GitHub-Action@5.3.8 with: diff --git a/src/LittleTown.Core.Tests/TestResults/TestResults.trx b/src/LittleTown.Core.Tests/TestResults/TestResults.trx deleted file mode 100644 index 58ac072..0000000 --- a/src/LittleTown.Core.Tests/TestResults/TestResults.trx +++ /dev/null @@ -1,62 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - NUnit Adapter 4.6.0.0: Test execution started -Running all tests in D:\Sandbox\projets\LittleTown\src\LittleTown.Core.Tests\bin\Debug\net8.0\LittleTown.Core.Tests.dll - NUnit3TestExecutor discovered 0 of 0 NUnit test cases using Current Discovery mode, Explicit run -NUnit Adapter 4.6.0.0: Test execution complete -[xUnit.net 00:00:00.00] xUnit.net VSTest Adapter v2.4.5+1caef2f33e (64-bit .NET 8.0.1) -[xUnit.net 00:00:00.31] Discovering: LittleTown.Core.Tests -[xUnit.net 00:00:00.33] Discovered: LittleTown.Core.Tests -[xUnit.net 00:00:00.33] Starting: LittleTown.Core.Tests -[xUnit.net 00:00:00.43] Finished: LittleTown.Core.Tests - - - - \ No newline at end of file -- 2.49.1 From f520cf249642a2fd42419630768d7488ce95708c Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Mon, 26 Aug 2024 23:39:40 +0200 Subject: [PATCH 35/39] suite7 --- .gitea/workflows/Quality.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index fa453b9..12d6bc9 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -36,7 +36,7 @@ jobs: run: | dotnet test ./src/LittleTown.sln --configuration Release --logger "trx;LogFileName=TestResults.trx" --collect:"XPlat Code Coverage" dotnet tool install -g dotnet-reportgenerator-globaltool - reportgenerator "-reports:TestResults.trx" "-targetdir:./report" "-reporttypes:Html" + reportgenerator "-reports:src/LittleTown.Core.Tests/TestResult/TestResults.trx" "-targetdir:./report" "-reporttypes:Html" - name: Combine Coverage Reports # This is because one report is produced per project, and we want one result for all of them. uses: danielpalme/ReportGenerator-GitHub-Action@5.3.8 with: -- 2.49.1 From 8cc895649bf2c108e48dfa97f0be05421a9c6195 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Thu, 29 Aug 2024 18:49:55 +0200 Subject: [PATCH 36/39] ready --- .gitea/workflows/Quality.yaml | 9 --------- .gitea/workflows/tests.yaml | 24 ------------------------ 2 files changed, 33 deletions(-) delete mode 100644 .gitea/workflows/tests.yaml diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index 12d6bc9..376e781 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -82,12 +82,3 @@ jobs: -d "{\"body\": \"${COMMENT_CONTENT}\"}" \ ${GITEA_URL}/api/v1/repos/${REPO_OWNER}/${REPO_NAME}/issues/${PR_NUMBER}/comments - - name: Upload Test Result Files - uses: actions/upload-artifact@v3 - with: - name: test-results - path: ${{ github.workspace }}/**/TestResults/**/* - retention-days: 5 - - name: debug - run : ls - diff --git a/.gitea/workflows/tests.yaml b/.gitea/workflows/tests.yaml deleted file mode 100644 index df42205..0000000 --- a/.gitea/workflows/tests.yaml +++ /dev/null @@ -1,24 +0,0 @@ -name: dotnet package - -on: [push] - -jobs: - build: - - runs-on: ubuntu-latest - strategy: - matrix: - dotnet-version: [ '8.0.x' ] - - steps: - - uses: actions/checkout@v4 - - name: Setup dotnet - uses: actions/setup-dotnet@v3 - with: - dotnet-version: '8.0.x' - - name: Install dependencies - run: dotnet restore ./src/LittleTown.sln - - name: Build - run: dotnet build ./src/LittleTown.sln - - name: Test with the dotnet CLI - run: dotnet test ./src/LittleTown.sln \ No newline at end of file -- 2.49.1 From 653ccf8399e2f8d8ea2b3f7127c0392bfbbfcc46 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Thu, 29 Aug 2024 18:59:27 +0200 Subject: [PATCH 37/39] ready2 --- .gitea/workflows/Quality.yaml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index 376e781..ab47fe7 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -32,11 +32,10 @@ jobs: with: dotnet-version: | 8.x + - name: "Restore/Build/Test" - name: "Restore/Build/Test" run: | - dotnet test ./src/LittleTown.sln --configuration Release --logger "trx;LogFileName=TestResults.trx" --collect:"XPlat Code Coverage" - dotnet tool install -g dotnet-reportgenerator-globaltool - reportgenerator "-reports:src/LittleTown.Core.Tests/TestResult/TestResults.trx" "-targetdir:./report" "-reporttypes:Html" + dotnet test ./src/LittleTown.sln --configuration Release --verbosity normal --logger trx --collect:"XPlat Code Coverage" --logger:"trx;LogFileName=test_results.xml" dotnet test ./src/LittleTown.sln --configuration Release --verbosity normal --logger trx --collect:"XPlat Code Coverage" --logger:"trx;LogFileName=test_results.xml" - name: Combine Coverage Reports # This is because one report is produced per project, and we want one result for all of them. uses: danielpalme/ReportGenerator-GitHub-Action@5.3.8 with: -- 2.49.1 From 20dd1d3a69f19b62ccb132265d44e29ee83900ce Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Thu, 29 Aug 2024 19:23:56 +0200 Subject: [PATCH 38/39] ready3 --- .gitea/workflows/Quality.yaml | 1 - 1 file changed, 1 deletion(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index ab47fe7..e6b1a1d 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -32,7 +32,6 @@ jobs: with: dotnet-version: | 8.x - - name: "Restore/Build/Test" - name: "Restore/Build/Test" run: | dotnet test ./src/LittleTown.sln --configuration Release --verbosity normal --logger trx --collect:"XPlat Code Coverage" --logger:"trx;LogFileName=test_results.xml" dotnet test ./src/LittleTown.sln --configuration Release --verbosity normal --logger trx --collect:"XPlat Code Coverage" --logger:"trx;LogFileName=test_results.xml" -- 2.49.1 From 6145e0076980689a9e530ffacde9bc2bd86da114 Mon Sep 17 00:00:00 2001 From: mcmuzzle Date: Thu, 29 Aug 2024 19:29:24 +0200 Subject: [PATCH 39/39] ready4 --- .gitea/workflows/Quality.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitea/workflows/Quality.yaml b/.gitea/workflows/Quality.yaml index e6b1a1d..6990f85 100644 --- a/.gitea/workflows/Quality.yaml +++ b/.gitea/workflows/Quality.yaml @@ -34,7 +34,7 @@ jobs: 8.x - name: "Restore/Build/Test" run: | - dotnet test ./src/LittleTown.sln --configuration Release --verbosity normal --logger trx --collect:"XPlat Code Coverage" --logger:"trx;LogFileName=test_results.xml" dotnet test ./src/LittleTown.sln --configuration Release --verbosity normal --logger trx --collect:"XPlat Code Coverage" --logger:"trx;LogFileName=test_results.xml" + dotnet test ./src/LittleTown.sln --configuration Release --verbosity normal --logger trx --collect:"XPlat Code Coverage" --logger:"trx;LogFileName=test_results.xml" - name: Combine Coverage Reports # This is because one report is produced per project, and we want one result for all of them. uses: danielpalme/ReportGenerator-GitHub-Action@5.3.8 with: -- 2.49.1