Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(action): modified workflow for beta #18

Merged
merged 15 commits into from
Sep 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 20 additions & 4 deletions .github/workflows/beta.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,10 @@ on:
types:
- opened
- reopened
- edited
- synchronize
branches:
- 'beta'
- beta

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
Expand Down Expand Up @@ -47,11 +49,18 @@ jobs:
- name: Lint
run: npm run lint

- name: Test
run: npm run test
- name: Vitest - Test & Coverage
run: npm run coverage

- name: Archive vitest code coverage results
uses: actions/upload-artifact@v4
with:
name: vitest-code-coverage-report
path: ./coverage/

sonarcloud:
name: SonarCloud
needs: install
runs-on: ${{ matrix.os }}

strategy:
Expand All @@ -63,6 +72,13 @@ jobs:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
- name: Download vitest code coverage results
uses: actions/download-artifact@v4
with:
name: vitest-code-coverage-report
path: ./coverage/
- name: check
run: cd coverage && find .
- name: SonarCloud Scan
uses: SonarSource/sonarcloud-github-action@master
env:
Expand All @@ -71,7 +87,7 @@ jobs:

semantic-version:
name: Semantic Release
needs: install
needs: sonarcloud
runs-on: ${{ matrix.os }}

strategy:
Expand Down
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
node_modules
/.env
/.coverage
/.DS_Store
/coverage
3 changes: 2 additions & 1 deletion sonar-project.properties
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
sonar.projectKey=basics_rxjs-collection
sonar.organization=basics

sonar.cpd.exclusions=packages/**/*.test.js
sonar.cpd.exclusions=./packages/**/*.test.js
sonar.javascript.lcov.reportPaths=./coverage/lcov.info

# This is the name and version displayed in the SonarCloud UI.
#sonar.projectName=rxjs-collection
Expand Down
4 changes: 2 additions & 2 deletions vitest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ export default defineConfig({
test: {
coverage: {
provider: 'v8',
reporter: ['text', 'json'],
reportsDirectory: './.coverage',
reporter: ['text', 'json', 'lcov'],
reportsDirectory: './coverage',
exclude: [
...configDefaults.exclude,
'commitlint.config.js',
Expand Down
Loading