ref(js): Remove acceptance test env and related code
IS_ACCEPTANCE_TEST and its associated dynamic text/static text behavior were removed from the codebase.
Changes include:
- The
IS_ACCEPTANCE_TESTconstant was removed fromstatic/app/constants/index.tsx. - Build configurations in
rspack.config.tsandconfig/build-chartcuterie.tswere updated to remove references toIS_ACCEPTANCE_TEST. - The
getDynamicTextutility instatic/app/utils/getDynamicText.tsxwas simplified to always return thevalueparameter, eliminating the conditionalfixedtext behavior. Its corresponding test file,static/app/utils/getDynamicText.spec.tsx, was deleted. - The
testableTransitionutility instatic/app/utils/testableTransition.tsxwas simplified to always return the provided transition, removing logic that conditionally disabled animations for acceptance tests. - The
useResizablehook and related constants (SECONDARY_SIDEBAR_MIN_WIDTH,SECONDARY_SIDEBAR_MAX_WIDTH) were removed, simplifyingstatic/app/views/nav/secondary/secondarySidebar.tsxandstatic/app/views/nav/sidebar.tsx. - Conditional logic relying on
deprecateTransactionAlertswas removed fromstatic/app/views/discover/savedQuery/index.tsx,static/app/views/performance/transactionSummary/header.tsx, andstatic/app/views/performance/vitalDetail/vitalDetailContent.tsx. - Test files
static/app/views/explore/multiQueryMode/queryConstructors/menu.tsxandstatic/app/views/explore/multiQueryMode/locationUtils.tsxwere updated, andstatic/app/views/explore/multiQueryMode/queryRow.tsxwas adjusted to remove duplicate/delete query functionality. - The
build-acceptancescript inpackage.jsonwas modified to remove only theIS_ACCEPTANCE_TEST=1environment variable, preserving the script itself.
This streamlines the codebase by removing legacy testing-specific conditional rendering and animation logic.
🚨 Warning: This pull request contains Frontend and Backend changes!
It's discouraged to make changes to Sentry's Frontend and Backend in a single pull request. The Frontend and Backend are not atomically deployed. If the changes are interdependent of each other, they must be separated into two pull requests and be made forward or backwards compatible, such that the Backend or Frontend can be safely deployed independently.
Have questions? Please ask in the #discuss-dev-infra channel.
:x: 7 Tests Failed:
| Tests completed | Failed | Passed | Skipped |
|---|---|---|---|
| 37168 | 7 | 37161 | 240 |
View the top 3 failed test(s) by shortest run time
DeleteBillingMetricHistory closes modal when Cancel button is clickedStack Traces | 0.083s run time
Error: expect(element).not.toBeInTheDocument() expected document not to contain element, found <header class="css-11ph1ym-ModalHeader eoiks233">Delete Billing Metric History<button aria-label="Close Modal" class="e1b0h4f90 eoiks232 css-1h6a9m9-StyledButton-getFocusState-getColors-getSizeStyles-getBoxShadow-DO_NOT_USE_getButtonStyles-DO_NOT_USE_getButtonStyles-CloseButton-withChonk e140qn372" role="button" type="button"><span class="css-1cv7pa9-InteractionStateLayer-InteractionStateLayer-InteractionStateLayer-InteractionStateLayer e18pngx40" role="presentation" /><span class="css-18eu2j5-ButtonLabel e140qn371"><span class="css-1prnm9c-Icon e140qn370"><svg data-test-id="icon-close" fill="currentColor" height="12px" kind="path" role="img" viewBox="0 0 16 16" width="12px"><path d="M6.94,8,1.47,13.47a.75.75,0,0,0,0,1.06.75.75,0,0,0,1.06,0L8,9.06l5.47,5.47a.75.75,0,0,0,1.06,0,.75.75,0,0,0,0-1.06L9.06,8l5.47-5.47a.75.75,0,0,0-1.06-1.06L8,6.94,2.53,1.47A.75.75,0,0,0,1.47,2.53Z" /></svg></span></span></button></header> instead at Object.<anonymous> (.../gsAdmin/components/deleteBillingMetricHistory.spec.tsx:339:90)
Confirm async onConfirm should not close the modal until the promise is resolvedStack Traces | 0.105s run time
Error: expect(element).not.toBeInTheDocument() expected document not to contain element, found <div aria-modal="true" class="css-1138fj1-Modal e1g5id4l1" role="dialog" style="opacity: 0; transform: translateY(14.791856729376342px);"><div class="css-1c9jtkf-Content e1g5id4l0" role="document"><section class="css-c7spxd-ModalBody eoiks231"><p style="word-wrap: break-word;">Are you sure?</p></section><footer class="css-1w0jaa6-ModalFooter eoiks230"><div class="css-105g0bz-StyledButtonBar e1mlz5570"><button aria-label="Cancel" class="css-1xp630d-StyledButton-getColors-getFocusState-getColors-getSizeStyles-getBoxShadow-DO_NOT_USE_getButtonStyles e140qn372" role="button" type="button"><span class="css-1cv7pa9-InteractionStateLayer-InteractionStateLayer-InteractionStateLayer-InteractionStateLayer e18pngx40" role="presentation" /><span class="css-18eu2j5-ButtonLabel e140qn371">Cancel</span></button><button aria-disabled="true" aria-label="Confirm" class="css-ariwwp-StyledButton-getColors-getFocusState-getColors-getSizeStyles-getBoxShadow-DO_NOT_USE_getButtonStyles e140qn372" data-test-id="confirm-button" disabled="" role="button" type="button"><span class="css-1hrcpgg-InteractionStateLayer-InteractionStateLayer-InteractionStateLayer-InteractionStateLayer e18pngx40" role="presentation" /><span class="css-18eu2j5-ButtonLabel e140qn371">Confirm</span></button></div></footer></div></div> instead Ignored nodes: comments, script, style ... at .../app/components/confirm.spec.tsx:159:71 at runWithExpensiveErrorDiagnosticsDisabled (.../sentry/node_modules/.pnpm/@[email protected]/node_modules/@.../dom/dist/config.js:47:12) at checkCallback (.../sentry/node_modules/.pnpm/@[email protected]/node_modules/@.../dom/dist/wait-for.js:124:77) at .../sentry/node_modules/.pnpm/@[email protected]/node_modules/@.../dom/dist/wait-for.js:82:9
IssueViewsHeader edit menu can delete a viewStack Traces | 0.243s run time
Error: expect(element).not.toBeInTheDocument() expected document not to contain element, found <div aria-modal="true" class="css-1138fj1-Modal e1g5id4l1" role="dialog" style="opacity: 0.1937097122782042; transform: translateY(-7.546396955942445px);"><div class="css-1c9jtkf-Content e1g5id4l0" role="document"><section class="css-c7spxd-ModalBody eoiks231"><p style="word-wrap: break-word;">Are you sure you want to delete the view "Test View"?</p></section><footer class="css-1w0jaa6-ModalFooter eoiks230"><div class="css-105g0bz-StyledButtonBar e1mlz5570"><button aria-label="Cancel" class="css-1xp630d-StyledButton-getColors-getFocusState-getColors-getSizeStyles-getBoxShadow-DO_NOT_USE_getButtonStyles e140qn372" role="button" type="button"><span class="css-1cv7pa9-InteractionStateLayer-InteractionStateLayer-InteractionStateLayer-InteractionStateLayer e18pngx40" role="presentation" /><span class="css-18eu2j5-ButtonLabel e140qn371">Cancel</span></button><button aria-disabled="true" aria-label="Delete View" class="css-ariwwp-StyledButton-getColors-getFocusState-getColors-getSizeStyles-getBoxShadow-DO_NOT_USE_getButtonStyles e140qn372" data-test-id="confirm-button" disabled="" role="button" type="button"><span class="css-1hrcpgg-InteractionStateLayer-InteractionStateLayer-InteractionStateLayer-InteractionStateLayer e18pngx40" role="presentation" /><span class="css-18eu2j5-ButtonLabel e140qn371">Delete View</span></button></div></footer></div></div> instead at Object.<anonymous> (.../views/issueList/issueViewsHeader.spec.tsx:95:69)
To view more test analytics, go to the Test Analytics Dashboard 📋 Got 3 mins? Take this short survey to help us improve Test Analytics.