1 import { OSDsPageHelper } from './osds.po';
3 describe('OSDs page', () => {
4 const osds = new OSDsPageHelper();
11 describe('breadcrumb and tab tests', () => {
12 it('should open and show breadcrumb', () => {
13 osds.expectBreadcrumbText('OSDs');
16 it('should show two tabs', () => {
17 osds.getTabsCount().should('eq', 2);
18 osds.getTabText(0).should('eq', 'OSDs List');
19 osds.getTabText(1).should('eq', 'Overall Performance');
23 describe('check existence of fields on OSD page', () => {
24 it('should check that number of rows and count in footer match', () => {
25 osds.getTableTotalCount().then((text) => {
26 osds.getTableRows().its('length').should('equal', text);
30 it('should verify that buttons exist', () => {
31 cy.contains('button', 'Create');
32 cy.contains('button', 'Cluster-wide configuration');
35 describe('by selecting one row in OSDs List', () => {
37 osds.getExpandCollapseElement().click();
40 it('should verify that selected footer increases', () => {
41 osds.getTableSelectedCount().should('equal', 1);
44 it('should show the correct text for the tab labels', () => {
45 cy.get('#tabset-osd-details > div > tab').then(($tabs) => {
46 const tabHeadings = $tabs.map((_i, e) => e.getAttribute('heading')).get();
48 expect(tabHeadings).to.eql([
50 'Attributes (OSD map)',
53 'Performance counter',