-
Notifications
You must be signed in to change notification settings - Fork 113
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
Add tests for workspace deletion #1631
base: main
Are you sure you want to change the base?
Add tests for workspace deletion #1631
Conversation
Signed-off-by: Qxisylolo <[email protected]>
describe('delete a workspace successfully using action buttons', () => { | ||
it('should successfully load delete button and show delete modal when clicking action button', () => { | ||
cy.contains(workspace1Name).should('be.visible'); | ||
cy.getElementByTestId('euiCollapsedItemActionsButton').first().click(); |
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 there any other way to find this button?
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.
can we use cy.getElementByTestId(`checkboxSelectRow-${workspaceId}`)
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.
Thank you for all the comments, updated.
cy.createWorkspace({ | ||
name: workspace1Name, | ||
description: workspace1Description, | ||
features: ['workspace_detail', 'use-case-observability'], |
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.
features: ['workspace_detail', 'use-case-observability'], | |
features: ['use-case-observability'], |
describe('delete a workspace successfully using action buttons', () => { | ||
it('should successfully load delete button and show delete modal when clicking action button', () => { | ||
cy.contains(workspace1Name).should('be.visible'); | ||
cy.getElementByTestId('euiCollapsedItemActionsButton').first().click(); |
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.
can we use cy.getElementByTestId(`checkboxSelectRow-${workspaceId}`)
Signed-off-by: Qxisylolo <[email protected]>
if (Cypress.env('WORKSPACE_ENABLED')) { | ||
describe('Delete Workspace(s) in 2 ways in workspace list page', () => { | ||
before(() => { | ||
Cypress.config('defaultCommandTimeout', 60000); |
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.
Do we need this line?
@Qxisylolo Test cases failed, could you please take a look? |
Description
This PR adds tests for workspace deletion, covering three methods:
Issues Resolved
[List any issues this PR will resolve]
Check List
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.