Skip to content

Commit

Permalink
updating more ci configs
Browse files Browse the repository at this point in the history
  • Loading branch information
alanmmolina committed Jul 14, 2024
1 parent 0c24191 commit 8361cb7
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 4 deletions.
5 changes: 5 additions & 0 deletions .github/workflows/code-coverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ jobs:
options: --security-opt seccomp=unconfined

steps:

- uses: actions/checkout@v2
with:
fetch-depth: 0
Expand All @@ -28,6 +29,10 @@ jobs:
run: |
cargo +nightly tarpaulin --verbose --all-features --workspace --timeout 120 --out xml --fail-under 50
- uses: actions/checkout@v2
with:
fetch-depth: 0

- name: Upload to codecov.io
uses: codecov/codecov-action@v1.0.2
with:
Expand Down
13 changes: 11 additions & 2 deletions .github/workflows/code-quality.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,13 @@ jobs:

steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0

- name: Setup Environment
run: |
echo "SONAR_ORGANIZATION=${{ github.repository_owner }}" >> $GITHUB_ENV
echo "SONAR_PROJECT_KEY=${{ github.repository_owner }}_${{ github.event.repository.name }}" >> $GITHUB_ENV
- name: Cache `cargo` Registry
uses: actions/cache@v2
Expand Down Expand Up @@ -72,11 +79,13 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONARCLOUD_TOKEN }}
SONAR_ORGANIZATION: ${{ env.SONAR_ORGANIZATION }}
SONAR_PROJECT_KEY: ${{ env.SONAR_PROJECT_KEY }}
with:
args: >
-Dsonar.host.url=https://sonarcloud.io
-Dsonar.projectKey=postech-5soat-grupo-25_tech-challenge-pedido-produto
-Dsonar.organization=postech-5soat-grupo-25
-Dsonar.projectKey=${{ env.SONAR_PROJECT_KEY }}
-Dsonar.organization=${{ env.SONAR_ORGANIZATION }}
-Dsonar.sources=src
-Dsonar.language=rust
-Dsonar.externalIssuesReportPaths=sonar-issues.json
Expand Down
10 changes: 8 additions & 2 deletions .github/workflows/unit-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,13 +36,19 @@ jobs:
id: report
uses: innoq/action-cargo-test-report@main
with:
cargo-test-report-json: 'results.json'
cargo-test-report-json: results.json

- name: Publish Test Report
uses: mikepenz/action-junit-report@main
if: always()
with:
check_name: Report
check_name: Results
fail_on_failure: true
require_tests: true
summary: ${{ steps.report.outputs.summary }}

- name: Archive Results
uses: actions/upload-artifact@v1
with:
name: unit-tests-report
path: results.json

0 comments on commit 8361cb7

Please sign in to comment.