mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 01:56:46 +00:00
feat: Add credentials E2E test suite and page object (#4596)
* fix: Fix inferred type of X cannot be named error after pnpm update * feat: Change page objects to expose actions and getters. Add credential creation suite
This commit is contained in:
17
cypress/pages/credentials.ts
Normal file
17
cypress/pages/credentials.ts
Normal file
@@ -0,0 +1,17 @@
|
||||
import { BasePage } from "./base";
|
||||
|
||||
export class CredentialsPage extends BasePage {
|
||||
url = '/credentials';
|
||||
getters = {
|
||||
emptyListCreateCredentialButton: () => cy.getByTestId('empty-resources-list').find('button'),
|
||||
createCredentialButton: () => cy.getByTestId('resources-list-add'),
|
||||
searchBar: () => cy.getByTestId('resources-list-search'),
|
||||
credentialCards: () => cy.getByTestId('credential-card'),
|
||||
credentialCard: (credentialName: string) => cy.getByTestId('credential-card')
|
||||
.contains(credentialName)
|
||||
.parents('[data-test-id="credential-card"]'),
|
||||
credentialCardActions: (credentialName: string) => this.getters.credentialCard(credentialName)
|
||||
.findChildByTestId('credential-card-actions'),
|
||||
credentialDeleteButton: () => cy.getByTestId('action-toggle-dropdown').filter(':visible').contains('Delete')
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user