mirror of
https://github.com/zitadel/zitadel.git
synced 2025-01-09 19:33:40 +00:00
make tests less flaky
This commit is contained in:
parent
69ac3444d2
commit
7b1e22357d
@ -23,7 +23,7 @@ describe('humans', () => {
|
||||
});
|
||||
|
||||
it('should add a user', () => {
|
||||
cy.get('[data-e2e="create-user-button"]').click();
|
||||
cy.get('[data-e2e="action-key-add"]').parents('[data-e2e="create-user-button"]').click();
|
||||
cy.url().should('contain', 'users/create');
|
||||
cy.get('[formcontrolname="email"]').type(username('e2ehuman'));
|
||||
//force needed due to the prefilled username prefix
|
||||
|
@ -23,7 +23,7 @@ describe('machines', () => {
|
||||
});
|
||||
|
||||
it('should add a machine', () => {
|
||||
cy.get('[data-e2e="create-user-button"]').click();
|
||||
cy.get('[data-e2e="action-key-add"]').parents('[data-e2e="create-user-button"]').click();
|
||||
cy.url().should('contain', 'users/create-machine');
|
||||
//force needed due to the prefilled username prefix
|
||||
cy.get('[formcontrolname="userName"]').type(testMachineUserNameAdd, { force: true });
|
||||
|
@ -25,11 +25,11 @@ describe('permissions', () => {
|
||||
ensureProjectExists(apiCalls, testProjectName).then(projId => {
|
||||
projectId = projId
|
||||
cy.visit(`${Cypress.env('baseUrl')}/ui/console/projects/${projId}?id=roles`)
|
||||
cy.get('[data-e2e=timestamp]');
|
||||
})
|
||||
})
|
||||
})
|
||||
|
||||
|
||||
describe('add role', () => {
|
||||
beforeEach(()=> {
|
||||
ensureProjectResourceDoesntExist(api, projectId, Roles, testRoleName)
|
||||
|
@ -44,8 +44,9 @@ describe('projects', () => {
|
||||
cy.get('[data-e2e=toggle-grid]').click();
|
||||
cy.get('[data-e2e=timestamp]');
|
||||
cy.contains('tr', testProjectNameDeleteList, { timeout: 1000 })
|
||||
.find('[data-e2e=table-actions-button]')
|
||||
.find('[data-e2e=delete-project-button]')
|
||||
.click({force: true});
|
||||
cy.get('[e2e-data="confirm-dialog-input"]').type(testProjectNameDeleteList);
|
||||
cy.get('[e2e-data="confirm-dialog-button"]').click();
|
||||
cy.get('.data-e2e-success');
|
||||
cy.wait(200);
|
||||
|
@ -6,7 +6,7 @@
|
||||
<span>ESC</span>
|
||||
</div>
|
||||
</div>
|
||||
<div *ngSwitchCase="ActionKeysType.ADD" class="action-keys-row">
|
||||
<div *ngSwitchCase="ActionKeysType.ADD" class="action-keys-row" [attr.data-e2e]="'action-key-add'">
|
||||
<div class="action-key">
|
||||
<div class="key-overlay"></div>
|
||||
<span>N</span>
|
||||
|
@ -5,8 +5,8 @@
|
||||
|
||||
<ng-template cnslHasRole [hasRole]="['project.role.write:' + projectId, 'project.role.write']" actions>
|
||||
<a *ngIf="actionsVisible" [disabled]="disabled" [routerLink]="[ '/projects', projectId, 'roles', 'create']"
|
||||
color="primary" class="cnsl-action-button" mat-raised-button [attr.data-e2e]="'add-new-role'">
|
||||
<mat-icon class="icon">add</mat-icon>
|
||||
color="primary" class="cnsl-action-button" mat-raised-button>
|
||||
<mat-icon [attr.data-e2e]="'add-new-role'" class="icon">add</mat-icon>
|
||||
<span>{{ 'ACTIONS.NEW' | translate }}</span>
|
||||
<cnsl-action-keys (actionTriggered)="gotoRouterLink([ '/projects', projectId, 'roles', 'create'])">
|
||||
</cnsl-action-keys>
|
||||
|
@ -84,7 +84,8 @@
|
||||
<td mat-cell *matCellDef="let project">
|
||||
<cnsl-table-actions>
|
||||
<button actions *ngIf="project.id !== zitadelProjectId" color="warn" mat-icon-button
|
||||
matTooltip="{{'ACTIONS.DELETE' | translate}}" (click)="deleteProject(project.id, project.name)">
|
||||
matTooltip="{{'ACTIONS.DELETE' | translate}}" (click)="deleteProject(project.id, project.name)"
|
||||
[attr.data-e2e]="'delete-project-button'">
|
||||
<i class="las la-trash"></i>
|
||||
</button>
|
||||
</cnsl-table-actions>
|
||||
|
Loading…
x
Reference in New Issue
Block a user