Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions frontend/cypress/e2e/sandbox-lifecycle.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,14 @@ describe('Sandbox Lifecycle', () => {
cy.get('[data-testid="view-toggle-list"]').click();
});

// The list sits in the page's scrolling content area. With the filters and
// the pager above it, a row can start below the fold at the CI viewport,
// and Cypress counts a row its scroll container clips as not visible. Each
// row is scrolled to before it is checked.
it('displays sandbox list with different phases', () => {
cy.contains('my-agent').should('be.visible');
cy.contains('data-processor').should('be.visible');
cy.contains('broken-sandbox').should('be.visible');
['my-agent', 'data-processor', 'broken-sandbox'].forEach((name) => {
cy.contains(name).scrollIntoView().should('be.visible');
});
});

it('shows sandbox phase labels in table view', () => {
Expand Down
3 changes: 2 additions & 1 deletion frontend/cypress/support/intercepts.ts
Original file line number Diff line number Diff line change
Expand Up @@ -353,7 +353,8 @@ export const interceptMisc = () => {
}).as('draftSummary');

// What the sandbox list reads its "N pending rules" badges from.
cy.intercept('GET', /\/api\/v1\/workspaces\/[^/]+\/draft-summary$/, {
// The sandbox list names the sandboxes of its page (?sandbox=...).
cy.intercept('GET', /\/api\/v1\/workspaces\/[^/]+\/draft-summary(\?.*)?$/, {
statusCode: 200,
body: { sandboxes: [], totalPending: 0 },
}).as('workspaceDraftSummary');
Expand Down
Loading