1 import { PoolPageHelper } from '../pools/pools.po';
2 import { LogsPageHelper } from './logs.po';
4 describe('Logs page', () => {
5 const logs = new LogsPageHelper();
6 const pools = new PoolPageHelper();
8 const poolname = 'e2e_logs_test_pool';
9 const today = new Date();
10 let hour = today.getHours();
14 const minute = today.getMinutes();
18 Cypress.Cookies.preserveOnce('token');
21 describe('breadcrumb and tab tests', () => {
26 it('should open and show breadcrumb', () => {
27 logs.expectBreadcrumbText('Logs');
30 it('should show two tabs', () => {
31 logs.getTabsCount().should('eq', 2);
34 it('should show cluster logs tab at first', () => {
35 logs.getTabText(0).should('eq', 'Cluster Logs');
38 it('should show audit logs as a second tab', () => {
39 logs.getTabText(1).should('eq', 'Audit Logs');
43 describe('audit logs respond to pool creation and deletion test', () => {
44 it('should create pool and check audit logs reacted', () => {
45 pools.navigateTo('create');
46 pools.create(poolname, 8);
48 pools.existTableCell(poolname, true);
49 logs.checkAuditForPoolFunction(poolname, 'create', hour, minute);
52 it('should delete pool and check audit logs reacted', () => {
54 pools.delete(poolname);
55 logs.checkAuditForPoolFunction(poolname, 'delete', hour, minute);