-
Notifications
You must be signed in to change notification settings - Fork 3.2k
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
misc: receive afterSpec durations from app capture code, and report them to the Cloud API #29500
Conversation
@@ -289,6 +290,9 @@ export type ProtocolMetadata = ArtifactMetadata & { | |||
size: number | |||
offset: number | |||
} | |||
afterSpecDurations?: AfterSpecDurations & { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
AfterSpecDurations
is the shape that the protocol capture codebase will return; we're augmenting that with the total duration of afterSpec
, so the shape is modified here.
2 flaky tests on run #55746 ↗︎
Details:
cypress/e2e/commands/waiting.cy.js • 2 flaky tests • 5x-driver-chrome
Review all test suite changes for PR #29500 ↗︎ |
Co-authored-by: Ryan Manuel <[email protected]>
await this.invokeAsync('afterSpec', { isEssential: true }) | ||
const startTime = performance.now() + performance.timeOrigin | ||
|
||
debug({ startTime }) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we have a description here around what this is?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this debug can be removed- the important debug is on L191
fileSize: number | bigint | ||
specAccess: ReturnType<AppCaptureProtocolInterface['getDbMetadata']> | ||
} | undefined> { | ||
async uploadCaptureArtifact ({ uploadUrl, fileSize, filePath }: CaptureArtifact, captureErrorsOverride?: boolean) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is captureErrorsOverride just used for testing purposes?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep. Could refactor a bit to have caller pass in the env var to make things a little cleaner.
Released in This comment thread has been locked. If you are still experiencing this issue after upgrading to |
Additional details
Because of the bifurcation of Test Replay capture/upload logic, the durations that are recorded in the afterSpec process will be returned from the protocol capture codebase' afterSpec method. They're collected and reported to the
updateInstanceArtifacts
Cloud API endpoint.Steps to test
Verify that, once the related services PR is merged and released, these durations are reported to the update instance artifacts endpoint when recording a spec with Test Replay enabled. When running against staging, these durations should be queryable in Honeycomb.
How has the user experience changed?
PR Tasks
cypress-documentation
?type definitions
?