@@ -221,34 +221,6 @@ jobs:
221221 name : playwright-artifacts
222222 path : playwright-artifacts
223223
224- - name : Count new tests
225- id : count_tests
226- run : |
227- git fetch origin main:main
228- new_tests=0
229-
230- # Get list of changed test files
231- for file in $(git diff --name-only main...HEAD | grep -E '^tests/suites/.*\.(spec|test)\.(ts|tsx|js|jsx)$'); do
232- # Count tests in current version
233- if git show HEAD:"$file" > /dev/null 2>&1; then
234- current_tests=$(git show HEAD:"$file" | grep -E "test\([\'\"]" | wc -l)
235- else
236- current_tests=0
237- fi
238-
239- # Count tests in main version
240- if git show main:"$file" > /dev/null 2>&1; then
241- base_tests=$(git show main:"$file" | grep -E "test\([\'\"]" | wc -l)
242- else
243- base_tests=0
244- fi
245-
246- # Add difference to total
247- ((new_tests += current_tests - base_tests))
248- done
249-
250- echo "new_tests=$new_tests" >> $GITHUB_OUTPUT
251-
252224 - name : Update PR description
253225 uses : actions/github-script@v6
254226 with :
@@ -293,17 +265,14 @@ jobs:
293265 parseFloat(percent) > 0 ? 'πΊ' :
294266 parseFloat(percent) < 0 ? 'π½' : 'β
';
295267
296- const newTests = parseInt('${{ steps.count_tests.outputs.new_tests }}');
297- const testsStatus = newTests > 0 ? 'β¨' : 'β';
298-
299268 const ciSection = `## CI Results
300269
301270 ### Test Status: <span style="color: ${statusColor};">${status}</span>
302271 π [Full Report](${reportUrl})
303272
304- | Total | Passed | Failed | Flaky | Skipped | New Tests |
305- |:-----:|:------:|:------:|:-----:|:-------:|:---------:|
306- | ${testResults.total} | ${testResults.passed} | ${testResults.failed} | ${testResults.flaky} | ${testResults.skipped} | ${testsStatus} ${newTests} |
273+ | Total | Passed | Failed | Flaky | Skipped |
274+ |:-----:|:------:|:------:|:-----:|:-------:|
275+ | ${testResults.total} | ${testResults.passed} | ${testResults.failed} | ${testResults.flaky} | ${testResults.skipped} |
307276
308277 ### Bundle Size: ${bundleStatus}
309278 Current: ${formatSize(currentSize)} | Main: ${formatSize(mainSize)}
@@ -322,7 +291,6 @@ jobs:
322291 - Bundle size is measured for the entire 'dist' directory.
323292 - π indicates links to detailed reports.
324293 - πΊ indicates increase, π½ decrease, and β
no change in bundle size.
325- - ${testsStatus} indicates ${newTests} new test cases added in this PR.
326294 </details>`;
327295
328296 const { data: pullRequest } = await github.rest.pulls.get({
0 commit comments