-
Notifications
You must be signed in to change notification settings - Fork 264
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Check default limit values in UI while creating a Pod with the Form
- Loading branch information
Showing
5 changed files
with
113 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
16 changes: 16 additions & 0 deletions
16
cypress/e2e/po/components/workloads/pods/pod-container-general.po.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import LabeledInputPo from '@/cypress/e2e/po/components/labeled-input.po'; | ||
import ComponentPo from '@/cypress/e2e/po/components/component.po'; | ||
|
||
export class PodContainerGeneral extends ComponentPo { | ||
constructor(selector = '.dashboard-root') { | ||
super(selector); | ||
} | ||
|
||
inputImageName() { | ||
return new LabeledInputPo(cy.get('[placeholder="e.g. nginx:latest"]')); | ||
} | ||
|
||
createButton() { | ||
return this.self().find('[data-testid="form-save"]'); | ||
} | ||
} |
34 changes: 34 additions & 0 deletions
34
cypress/e2e/po/components/workloads/pods/pod-container-resources.po.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
import LabeledInputPo from '@/cypress/e2e/po/components/labeled-input.po'; | ||
import ComponentPo from '@/cypress/e2e/po/components/component.po'; | ||
|
||
export class PodContainerResources extends ComponentPo { | ||
constructor(selector = '.dashboard-root') { | ||
super(selector); | ||
} | ||
|
||
clickResources() { | ||
return this.self().get('[data-testid="btn-resources"]').first() | ||
.scrollIntoView() | ||
.click(); | ||
} | ||
|
||
inputCpuReservation() { | ||
return new LabeledInputPo(cy.get('[data-testid="cpu-reservation"]')); | ||
} | ||
|
||
inputMemoryReservation() { | ||
return new LabeledInputPo(cy.get('[data-testid="memory-reservation"]')); | ||
} | ||
|
||
inputCpuLimit() { | ||
return new LabeledInputPo(cy.get('[data-testid="cpu-limit"]')); | ||
} | ||
|
||
inputMemoryLimit() { | ||
return new LabeledInputPo(cy.get('[data-testid="memory-limit"]')); | ||
} | ||
|
||
inputGpuLimit() { | ||
return new LabeledInputPo(cy.get('[data-testid="gpu-limit"]')); | ||
} | ||
} |
12 changes: 12 additions & 0 deletions
12
cypress/e2e/po/components/workloads/pods/pod-container.po.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
import { PodContainerGeneral } from '@/cypress/e2e/po/components/workloads/pods/pod-container-general.po'; | ||
import { PodContainerResources } from '@/cypress/e2e/po/components/workloads/pods/pod-container-resources.po'; | ||
|
||
export class PodContainer { | ||
resources() { | ||
return new PodContainerResources('[data-testid="btn-resources"]'); | ||
} | ||
|
||
general() { | ||
return new PodContainerGeneral('[data-testid="btn-general"]'); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters