Skip to content

Commit

Permalink
e2e test for organization teams page
Browse files Browse the repository at this point in the history
  • Loading branch information
avzz-19 committed Oct 15, 2024
1 parent 2155055 commit a0e24c1
Show file tree
Hide file tree
Showing 9 changed files with 363 additions and 3 deletions.
6 changes: 5 additions & 1 deletion app/components/organization-invitation-list/index.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,11 @@
<AkTable data-test-invitation-list as |t|>
<t.head data-test-invitation-list-thead @columns={{this.columns}} />
<t.body @rows={{pgc.currentPageResults}} as |b|>
<b.row data-test-invitation-list-row as |r|>
<b.row
data-test-cy='invitationList-row'
data-test-invitation-list-row
as |r|
>
<r.cell data-test-invitation-list-cell as |value|>
{{#if r.columnValue.component}}
{{#let (component r.columnValue.component) as |Component|}}
Expand Down
2 changes: 1 addition & 1 deletion app/components/organization-team/add-team-member/index.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@
<AkTable @dense={{true}} as |t|>
<t.head data-test-addUserList-thead @columns={{this.columns}} />
<t.body @rows={{pgc.currentPageResults}} as |b|>
<b.row data-test-addUserList-row as |r|>
<b.row data-test-cy='userList-row' data-test-addUserList-row as |r|>
<r.cell data-test-addUserList-cell as |value|>
{{#if r.columnValue.component}}
{{#let (component r.columnValue.component) as |CheckBox|}}
Expand Down
6 changes: 5 additions & 1 deletion app/components/organization-team/add-team-project/index.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,11 @@
<AkTable @dense={{true}} as |t|>
<t.head data-test-addProjectList-thead @columns={{this.columns}} />
<t.body @rows={{pgc.currentPageResults}} as |b|>
<b.row data-test-addProjectList-row as |r|>
<b.row
data-test-cy='addProjectList-row'
data-test-addProjectList-row
as |r|
>
<r.cell data-test-addProjectList-cell>
{{#if r.columnValue.component}}
{{#let (component r.columnValue.component) as |Component|}}
Expand Down
1 change: 1 addition & 0 deletions app/components/organization-team/create-team/index.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@

<AkButton
data-test-orgCreateTeam-submitBtn
data-test-cy='create-team-submit-btn'
class='mt-3'
@type='submit'
@loading={{this.isCreatingTeam}}
Expand Down
1 change: 1 addition & 0 deletions app/components/organization-team/details/index.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
</AkTypography>

<AkIconButton
data-test-cy='teamDetail-closeBtn'
class={{ab.classes.defaultIconBtn}}
{{on 'click' dr.closeHandler}}
>
Expand Down
2 changes: 2 additions & 0 deletions app/components/organization-team/overview/index.hbs
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
<AkStack
data-test-orgTeamOverview
data-test-cy='org-team-overview'
@direction='column'
role='button'
local-class='org-team-overview-container'
{{on 'click' this.showTeamDetails}}
>
<AkTypography
data-test-orgTeamOverview-name
data-test-cy='org-team-overview-name'
@variant='h5'
@color='primary'
@gutterBottom={{true}}
Expand Down
24 changes: 24 additions & 0 deletions cypress/support/api.routes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -93,4 +93,28 @@ export const API_ROUTES = {
route: '/api/service_accounts/*',
alias: 'serviceAccount',
},
teamsList: {
route: '/api/organizations/*/teams*',
alias: 'teamList',
},
editTeam: {
route: '/api/organizations/*/teams/*',
alias: 'editTeam',
},
organization: {
route: '/api/organizations/*',
alias: 'organization',
},
editUserInfo: {
route: '/api/organizations/*/users/*',
alias: 'editUser',
},
usersList: {
route: '/api/organizations/*/users*',
alias: 'usersList',
},
inviteTeam: {
route: '/api/organizations/*/teams/*/invitations*',
alias: 'inviteTeam',
},
} as const;
1 change: 1 addition & 0 deletions cypress/support/application.routes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,5 @@ export const APPLICATION_ROUTES = {
sbom: '/dashboard/sbom/apps',
serviceAccount: '/dashboard/organization/settings/service-account',
register: '/register',
organizationTeams: 'dashboard/organization/teams',
} as const;
Loading

0 comments on commit a0e24c1

Please sign in to comment.