Skip to content

Commit

Permalink
[Reporting/Tests] Consolidate test archives, move kbn objects to kbn_…
Browse files Browse the repository at this point in the history
…archiver (elastic#116528)

* remove unused

* remove kibana objects from reporting es_archives

* import objects using kibanaServer for tests

* consolidate ecommerce_kibana_spaces

* self-review

* fix nanos test

* fix loading of reporting/ecommerce_kibana_spaces

* fix csv snapshots

* fix more csv tests

* archive rename

* consolidate canvas_disallowed_url archive

* clean up snapshots

* fix CSV tests

* polish

* remove unused

* Update x-pack/test/reporting_api_integration/reporting_and_security/network_policy.ts
  • Loading branch information
tsullivan committed Nov 3, 2021
1 parent 3a33552 commit 95089e8
Show file tree
Hide file tree
Showing 29 changed files with 766 additions and 8,714 deletions.
9 changes: 2 additions & 7 deletions x-pack/test/accessibility/apps/reporting.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) {
const testSubjects = getService('testSubjects');
const supertestWithoutAuth = getService('supertestWithoutAuth');
const reporting = getService('reporting');
const esArchiver = getService('esArchiver');
const security = getService('security');

describe('Reporting', () => {
Expand All @@ -33,17 +32,13 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) {
};

before(async () => {
await esArchiver.load('x-pack/test/functional/es_archives/reporting/logs');
await esArchiver.load('x-pack/test/functional/es_archives/logstash_functional');

await reporting.initLogs();
await createReportingUser();
await reporting.loginReportingUser();
});

after(async () => {
await esArchiver.unload('x-pack/test/functional/es_archives/reporting/logs');
await esArchiver.unload('x-pack/test/functional/es_archives/logstash_functional');

await reporting.teardownLogs();
await deleteReportingUser();
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) {
const log = getService('log');
const testSubjects = getService('testSubjects');
const kibanaServer = getService('kibanaServer');
const reportingAPI = getService('reporting');
const filterBar = getService('filterBar');
const find = getService('find');
const retry = getService('retry');
Expand Down Expand Up @@ -124,9 +125,11 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) {

describe('Field Formatters and Scripted Fields', () => {
before(async () => {
await reportingAPI.initLogs();
await esArchiver.load('x-pack/test/functional/es_archives/reporting/hugedata');
});
after(async () => {
await reportingAPI.teardownLogs();
await esArchiver.unload('x-pack/test/functional/es_archives/reporting/hugedata');
});

Expand Down
Binary file not shown.
Loading

0 comments on commit 95089e8

Please sign in to comment.