38 lines
1.1 KiB
JavaScript
38 lines
1.1 KiB
JavaScript
import selectors from '../../helpers/selectors.js';
|
|
import getBrowser from '../../helpers/puppeteer';
|
|
|
|
describe('Account Accounts path', () => {
|
|
let browser;
|
|
let page;
|
|
|
|
beforeAll(async() => {
|
|
browser = await getBrowser();
|
|
page = browser.page;
|
|
await page.loginAndModule('sysadmin', 'account');
|
|
await page.accessToSection('account.accounts');
|
|
});
|
|
|
|
afterAll(async() => {
|
|
await browser.close();
|
|
});
|
|
|
|
it('should sync roles', async() => {
|
|
await page.waitToClick(selectors.accountAccounts.syncRoles);
|
|
const message = await page.waitForSnackbar();
|
|
|
|
expect(message.text).toContain('Roles synchronized!');
|
|
});
|
|
|
|
it('should relogin', async() => {
|
|
await page.loginAndModule('sysadmin', 'account');
|
|
await page.accessToSection('account.accounts');
|
|
});
|
|
|
|
it('should sync all', async() => {
|
|
await page.waitToClick(selectors.accountAccounts.syncAll);
|
|
const message = await page.waitForSnackbar();
|
|
|
|
expect(message.text).toContain('Synchronizing in the background');
|
|
});
|
|
});
|