From 0fda82da7a83833a34b28e0747750bb39af548c1 Mon Sep 17 00:00:00 2001 From: Clement Date: Sat, 4 May 2024 16:04:15 +0200 Subject: [PATCH 1/7] make some test --- .github/workflows/run_back_test.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/run_back_test.yml b/.github/workflows/run_back_test.yml index d677a8f..faa03ee 100644 --- a/.github/workflows/run_back_test.yml +++ b/.github/workflows/run_back_test.yml @@ -1,4 +1,4 @@ -name: 'coverage' +name: 'test and coverage' on: pull_request: branches: @@ -13,5 +13,5 @@ jobs: working-directory: Express/barAndCafe test-script: npm run test output: comment, report-markdown - prnumber: ${{ steps.findPr.outputs.number }} + # prnumber: ${{ steps.findPr.outputs.number }} custom-title: Coverage report for backend \ No newline at end of file -- 2.47.1 From bf94c5b262a98c9b56246aa5fa7e52141346ddd2 Mon Sep 17 00:00:00 2001 From: Clement Date: Sat, 4 May 2024 16:06:23 +0200 Subject: [PATCH 2/7] fix name --- .github/workflows/run_back_test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/run_back_test.yml b/.github/workflows/run_back_test.yml index faa03ee..5a1f162 100644 --- a/.github/workflows/run_back_test.yml +++ b/.github/workflows/run_back_test.yml @@ -1,4 +1,4 @@ -name: 'test and coverage' +name: Test and coverage on: pull_request: branches: -- 2.47.1 From 6c930911095fe030509d258b34a9e42e051c3a7a Mon Sep 17 00:00:00 2001 From: Clement Date: Sat, 4 May 2024 16:07:05 +0200 Subject: [PATCH 3/7] run on all branche --- .github/workflows/run_back_test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/run_back_test.yml b/.github/workflows/run_back_test.yml index 5a1f162..d75813b 100644 --- a/.github/workflows/run_back_test.yml +++ b/.github/workflows/run_back_test.yml @@ -2,7 +2,7 @@ name: Test and coverage on: pull_request: branches: - - master + - '*' jobs: coverage: runs-on: ubuntu-latest -- 2.47.1 From e3acfe1a922fb01c5bbd9cc17656480a110bf5f3 Mon Sep 17 00:00:00 2001 From: Clement Date: Sat, 4 May 2024 16:09:50 +0200 Subject: [PATCH 4/7] add pr number --- .github/workflows/run_back_test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/run_back_test.yml b/.github/workflows/run_back_test.yml index d75813b..d32c42f 100644 --- a/.github/workflows/run_back_test.yml +++ b/.github/workflows/run_back_test.yml @@ -13,5 +13,5 @@ jobs: working-directory: Express/barAndCafe test-script: npm run test output: comment, report-markdown - # prnumber: ${{ steps.findPr.outputs.number }} + prnumber: ${{ steps.findPr.outputs.number }} custom-title: Coverage report for backend \ No newline at end of file -- 2.47.1 From feef7c4cf11aeabbf539d6df4d3d37689125a98c Mon Sep 17 00:00:00 2001 From: Clement Date: Sat, 4 May 2024 16:15:20 +0200 Subject: [PATCH 5/7] add custom tocken --- .github/workflows/run_back_test.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/run_back_test.yml b/.github/workflows/run_back_test.yml index d32c42f..06c4ad6 100644 --- a/.github/workflows/run_back_test.yml +++ b/.github/workflows/run_back_test.yml @@ -14,4 +14,5 @@ jobs: test-script: npm run test output: comment, report-markdown prnumber: ${{ steps.findPr.outputs.number }} - custom-title: Coverage report for backend \ No newline at end of file + custom-title: Coverage report for backend + github-token: ${{ secrets.PR_TOCKEN}} \ No newline at end of file -- 2.47.1 From 0a85c94b0355244f7c7c7690d571c163695f8863 Mon Sep 17 00:00:00 2001 From: Clement Date: Sat, 4 May 2024 16:21:00 +0200 Subject: [PATCH 6/7] diasble annotation --- .github/workflows/run_back_test.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/run_back_test.yml b/.github/workflows/run_back_test.yml index 06c4ad6..e7f0722 100644 --- a/.github/workflows/run_back_test.yml +++ b/.github/workflows/run_back_test.yml @@ -15,4 +15,5 @@ jobs: output: comment, report-markdown prnumber: ${{ steps.findPr.outputs.number }} custom-title: Coverage report for backend - github-token: ${{ secrets.PR_TOCKEN}} \ No newline at end of file + github-token: ${{ secrets.PR_TOCKEN}} + annotations: none #disable annotation \ No newline at end of file -- 2.47.1 From e1c6f0d2818bd975af75b814987975b86ff793b5 Mon Sep 17 00:00:00 2001 From: Clement Date: Sat, 4 May 2024 16:25:12 +0200 Subject: [PATCH 7/7] add 80% of coverage --- Express/barAndCafe/jest.config.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Express/barAndCafe/jest.config.js b/Express/barAndCafe/jest.config.js index a4f7e45..66a64c8 100644 --- a/Express/barAndCafe/jest.config.js +++ b/Express/barAndCafe/jest.config.js @@ -11,4 +11,9 @@ module.exports = { '!/coverage/', '!**/server.ts', ], -}; \ No newline at end of file + coverageThreshold: { + global: { + lines: 80, + }, + }, +}; -- 2.47.1