devops: create blob reports for all "tests 1" (#26694)
This commit is contained in:
parent
c970179551
commit
39a6b23309
34
.github/workflows/tests_primary.yml
vendored
34
.github/workflows/tests_primary.yml
vendored
|
|
@ -158,10 +158,26 @@ jobs:
|
||||||
env:
|
env:
|
||||||
DEBUG: pw:install
|
DEBUG: pw:install
|
||||||
- run: npm run build
|
- run: npm run build
|
||||||
|
|
||||||
- run: npx playwright install --with-deps
|
- run: npx playwright install --with-deps
|
||||||
- run: npm run test-html-reporter
|
- run: npm run test-html-reporter
|
||||||
|
env:
|
||||||
|
PWTEST_BLOB_REPORT_NAME: "web-components-html-reporter"
|
||||||
|
- name: Upload blob report
|
||||||
|
if: always()
|
||||||
|
uses: ./.github/actions/upload-blob-report
|
||||||
|
with:
|
||||||
|
report_dir: packages/html-reporter/blob-report
|
||||||
|
|
||||||
- run: npm run test-web
|
- run: npm run test-web
|
||||||
if: always()
|
if: always()
|
||||||
|
env:
|
||||||
|
PWTEST_BLOB_REPORT_NAME: "web-components-web"
|
||||||
|
- name: Upload blob report
|
||||||
|
if: always()
|
||||||
|
uses: ./.github/actions/upload-blob-report
|
||||||
|
with:
|
||||||
|
report_dir: packages/web/blob-report
|
||||||
|
|
||||||
test_vscode_extension:
|
test_vscode_extension:
|
||||||
name: VSCode Extension
|
name: VSCode Extension
|
||||||
|
|
@ -189,9 +205,16 @@ jobs:
|
||||||
working-directory: ./playwright-vscode
|
working-directory: ./playwright-vscode
|
||||||
- name: Run extension tests
|
- name: Run extension tests
|
||||||
run: npm run test -- --workers=1
|
run: npm run test -- --workers=1
|
||||||
|
env:
|
||||||
|
PWTEST_BLOB_REPORT_NAME: "vscode-extension"
|
||||||
working-directory: ./playwright-vscode
|
working-directory: ./playwright-vscode
|
||||||
|
- name: Upload blob report
|
||||||
|
if: always()
|
||||||
|
uses: ./.github/actions/upload-blob-report
|
||||||
|
with:
|
||||||
|
report_dir: ./playwright-vscode/blob-report
|
||||||
|
|
||||||
test-package-installations:
|
test_package_installations:
|
||||||
name: "Installation Test ${{ matrix.os }}"
|
name: "Installation Test ${{ matrix.os }}"
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
strategy:
|
strategy:
|
||||||
|
|
@ -214,8 +237,17 @@ jobs:
|
||||||
- run: npx playwright install-deps
|
- run: npx playwright install-deps
|
||||||
- run: npm run itest
|
- run: npm run itest
|
||||||
if: matrix.os != 'ubuntu-latest'
|
if: matrix.os != 'ubuntu-latest'
|
||||||
|
env:
|
||||||
|
PWTEST_BLOB_REPORT_NAME: "package-installations-${{ matrix.os }}"
|
||||||
- run: xvfb-run --auto-servernum --server-args="-screen 0 1280x960x24" -- npm run itest
|
- run: xvfb-run --auto-servernum --server-args="-screen 0 1280x960x24" -- npm run itest
|
||||||
if: matrix.os == 'ubuntu-latest'
|
if: matrix.os == 'ubuntu-latest'
|
||||||
|
env:
|
||||||
|
PWTEST_BLOB_REPORT_NAME: "package-installations-${{ matrix.os }}"
|
||||||
- run: ./utils/upload_flakiness_dashboard.sh ./test-results/report.json
|
- run: ./utils/upload_flakiness_dashboard.sh ./test-results/report.json
|
||||||
if: always()
|
if: always()
|
||||||
shell: bash
|
shell: bash
|
||||||
|
- name: Upload blob report
|
||||||
|
if: always()
|
||||||
|
uses: ./.github/actions/upload-blob-report
|
||||||
|
with:
|
||||||
|
report_dir: blob-report
|
||||||
|
|
|
||||||
|
|
@ -21,7 +21,7 @@ export default defineConfig({
|
||||||
forbidOnly: !!process.env.CI,
|
forbidOnly: !!process.env.CI,
|
||||||
retries: process.env.CI ? 2 : 0,
|
retries: process.env.CI ? 2 : 0,
|
||||||
snapshotPathTemplate: '{testDir}/__screenshots__/{projectName}/{testFilePath}/{arg}{ext}',
|
snapshotPathTemplate: '{testDir}/__screenshots__/{projectName}/{testFilePath}/{arg}{ext}',
|
||||||
reporter: 'html',
|
reporter: process.env.CI ? 'blob' : 'html',
|
||||||
use: {
|
use: {
|
||||||
ctPort: 3101,
|
ctPort: 3101,
|
||||||
trace: 'on-first-retry',
|
trace: 'on-first-retry',
|
||||||
|
|
|
||||||
|
|
@ -15,12 +15,23 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
import { devices, defineConfig } from '@playwright/experimental-ct-react';
|
import { devices, defineConfig } from '@playwright/experimental-ct-react';
|
||||||
|
import type { ReporterDescription } from '@playwright/test';
|
||||||
|
|
||||||
|
const reporters = () => {
|
||||||
|
const result: ReporterDescription[] = process.env.CI ? [
|
||||||
|
['html'],
|
||||||
|
['blob'],
|
||||||
|
] : [
|
||||||
|
['html']
|
||||||
|
];
|
||||||
|
return result;
|
||||||
|
};
|
||||||
|
|
||||||
export default defineConfig({
|
export default defineConfig({
|
||||||
testDir: 'src',
|
testDir: 'src',
|
||||||
forbidOnly: !!process.env.CI,
|
forbidOnly: !!process.env.CI,
|
||||||
retries: process.env.CI ? 2 : 0,
|
retries: process.env.CI ? 2 : 0,
|
||||||
reporter: 'html',
|
reporter: reporters(),
|
||||||
use: {
|
use: {
|
||||||
ctPort: 3102,
|
ctPort: 3102,
|
||||||
trace: 'on-first-retry',
|
trace: 'on-first-retry',
|
||||||
|
|
|
||||||
|
|
@ -16,9 +16,22 @@
|
||||||
|
|
||||||
import path from 'path';
|
import path from 'path';
|
||||||
import { defineConfig } from '@playwright/test';
|
import { defineConfig } from '@playwright/test';
|
||||||
|
import type { ReporterDescription } from '@playwright/test';
|
||||||
import { config as loadEnv } from 'dotenv';
|
import { config as loadEnv } from 'dotenv';
|
||||||
loadEnv({ path: path.join(__dirname, '..', '..', '.env') });
|
loadEnv({ path: path.join(__dirname, '..', '..', '.env') });
|
||||||
|
|
||||||
|
const reporters = () => {
|
||||||
|
const result: ReporterDescription[] = process.env.CI ? [
|
||||||
|
['dot'],
|
||||||
|
['json', { outputFile: path.join(outputDir, 'report.json') }],
|
||||||
|
['blob'],
|
||||||
|
] : [
|
||||||
|
['list'],
|
||||||
|
['html', { open: 'on-failure' }]
|
||||||
|
];
|
||||||
|
return result;
|
||||||
|
};
|
||||||
|
|
||||||
const outputDir = path.join(__dirname, '..', '..', 'test-results');
|
const outputDir = path.join(__dirname, '..', '..', 'test-results');
|
||||||
export default defineConfig({
|
export default defineConfig({
|
||||||
globalSetup: path.join(__dirname, 'globalSetup'),
|
globalSetup: path.join(__dirname, 'globalSetup'),
|
||||||
|
|
@ -26,10 +39,7 @@ export default defineConfig({
|
||||||
testIgnore: '**\/fixture-scripts/**',
|
testIgnore: '**\/fixture-scripts/**',
|
||||||
timeout: 5 * 60 * 1000,
|
timeout: 5 * 60 * 1000,
|
||||||
retries: 0,
|
retries: 0,
|
||||||
reporter: process.env.CI ? [
|
reporter: reporters(),
|
||||||
['dot'],
|
|
||||||
['json', { outputFile: path.join(outputDir, 'report.json') }],
|
|
||||||
] : [['list'], ['html', { open: 'on-failure' }]],
|
|
||||||
forbidOnly: !!process.env.CI,
|
forbidOnly: !!process.env.CI,
|
||||||
workers: 1,
|
workers: 1,
|
||||||
projects: [
|
projects: [
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue