]> git.proxmox.com Git - ceph.git/blame - ceph/src/pybind/mgr/dashboard/frontend/cypress/integration/orchestrator/02-hosts-inventory.e2e-spec.ts
import ceph 16.2.7
[ceph.git] / ceph / src / pybind / mgr / dashboard / frontend / cypress / integration / orchestrator / 02-hosts-inventory.e2e-spec.ts
CommitLineData
f67539c2
TL
1import { HostsPageHelper } from '../cluster/hosts.po';
2
3describe('Hosts page', () => {
4 const hosts = new HostsPageHelper();
5
6 beforeEach(() => {
7 cy.login();
8 Cypress.Cookies.preserveOnce('token');
9 hosts.navigateTo();
10 });
11
12 describe('when Orchestrator is available', () => {
13 beforeEach(function () {
14 cy.fixture('orchestrator/inventory.json').as('hosts');
15 });
16
17 it('should display correct inventory', function () {
18 for (const host of this.hosts) {
a4b75251 19 hosts.clickTab('cd-host-details', host.name, 'Physical Disks');
f67539c2
TL
20 cy.get('cd-host-details').within(() => {
21 hosts.getTableCount('total').should('be.eq', host.devices.length);
22 });
23 }
24 });
25 });
26});