Playwright is a framework for Web Testing and Automation. It allows testing Chromium, Firefox and WebKit with a single API.
TypeScript automationchromechromiume2e-testingelectronend-to-end-testingfirefoxjavascriptplaywrighttesttest-automationtestingtesting-toolswebwebkit
fix(tracing): check if source exists before adding to zip (#10986)
Yury Semikhatskyeb9c8a8f065a
diff --git a/packages/playwright-core/src/server/trace/recorder/tracing.ts b/packages/playwright-core/src/server/trace/recorder/tracing.tsindex 59788cf100..c64e517c3e 100644--- a/packages/playwright-core/src/server/trace/recorder/tracing.ts+++ b/packages/playwright-core/src/server/trace/recorder/tracing.ts@@ -223,10 +223,12 @@ export class Tracing implements InstrumentationListener, SnapshotterDelegate, HasourceEntries = [];for (const value of state.sources) {const entry = { name: 'resources/src@' + calculateSha1(value) + '.txt', value };- if (params.mode === 'compressTraceAndSources')- entries.push(entry);- else+ if (params.mode === 'compressTraceAndSources') {+ if (fs.existsSync(entry.value))+ entries.push(entry);+ } else {sourceEntries.push(entry);+ }}}