Skip to content

Commit

Permalink
[Cases] fix create-case serverless flaky test (elastic#167991)
Browse files Browse the repository at this point in the history
  • Loading branch information
js-jankisalvi authored and dej611 committed Oct 17, 2023
1 parent d9a82b3 commit 7ccbce2
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,15 @@ export default ({ getService, getPageObject }: FtrProviderContext) => {
const testSubjects = getService('testSubjects');
const svlCommonPage = getPageObject('svlCommonPage');
const config = getService('config');
const header = getPageObject('header');

before(async () => {
await svlCommonPage.login();
});

beforeEach(async () => {
await navigateToCasesApp(getPageObject, getService, owner);
await header.waitUntilLoadingHasFinished();
});

after(async () => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ export default ({ getPageObject, getService }: FtrProviderContext) => {
});

after(async () => {
await cases.api.deleteAllCases();
await svlCommonPage.forceLogout();
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,22 +15,23 @@ import { navigateToCasesApp } from '../../../../../shared/lib/cases';
const owner = SECURITY_SOLUTION_OWNER;

export default ({ getService, getPageObject }: FtrProviderContext) => {
// FLAKY: https://github.com/elastic/kibana/issues/166842
describe.skip('Create Case', function () {
describe('Create Case', function () {
const find = getService('find');
const cases = getService('cases');
const testSubjects = getService('testSubjects');
const config = getService('config');
const svlCommonPage = getPageObject('svlCommonPage');

beforeEach(async () => {
await navigateToCasesApp(getPageObject, getService, owner);
});
const header = getPageObject('header');

before(async () => {
await svlCommonPage.login();
});

beforeEach(async () => {
await navigateToCasesApp(getPageObject, getService, owner);
await header.waitUntilLoadingHasFinished();
});

after(async () => {
await cases.api.deleteAllCases();
await svlCommonPage.forceLogout();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ export default ({ getPageObject, getService }: FtrProviderContext) => {
});

after(async () => {
await cases.api.deleteAllCases();
await svlCommonPage.forceLogout();
});

Expand Down

0 comments on commit 7ccbce2

Please sign in to comment.