Skip to content

Commit

Permalink
Undo test adaptions
Browse files Browse the repository at this point in the history
  • Loading branch information
kertal committed Apr 18, 2020
1 parent a50a210 commit cc76e78
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 37 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,9 @@ import { FtrProviderContext } from '../../../ftr_provider_context';

export default function({ getPageObjects, getService }: FtrProviderContext) {
const esArchiver = getService('esArchiver');
const retry = getService('retry');
const security = getService('security');
const globalNav = getService('globalNav');
const config = getService('config');
const log = getService('log');
const PageObjects = getPageObjects([
'common',
'discover',
Expand Down Expand Up @@ -186,15 +184,9 @@ export default function({ getPageObjects, getService }: FtrProviderContext) {

it(`doesn't show visualize button`, async () => {
await PageObjects.common.navigateToApp('discover');
await PageObjects.common.sleep(500);
await setDiscoverTimeRange();
await retry.try(async () => {
const hitCount = await PageObjects.discover.getHitCount();
log.debug('doesnt show visualize button: hit count', hitCount);
expect(parseInt(hitCount, 10)).to.be.greaterThan(0);
await PageObjects.discover.clickFieldListItem('bytes');
await PageObjects.discover.expectMissingFieldListItemVisualize('bytes');
});
await PageObjects.discover.clickFieldListItem('bytes');
await PageObjects.discover.expectMissingFieldListItemVisualize('bytes');
});

it(`Permalinks doesn't show create short-url button`, async () => {
Expand Down Expand Up @@ -281,15 +273,9 @@ export default function({ getPageObjects, getService }: FtrProviderContext) {

it(`doesn't show visualize button`, async () => {
await PageObjects.common.navigateToApp('discover');
await PageObjects.common.sleep(500);
await setDiscoverTimeRange();
await retry.try(async () => {
const hitCount = await PageObjects.discover.getHitCount();
log.debug('doesnt show visualize button: hit count', hitCount);
expect(parseInt(hitCount, 10)).to.be.greaterThan(0);
await PageObjects.discover.clickFieldListItem('bytes');
await PageObjects.discover.expectMissingFieldListItemVisualize('bytes');
});
await PageObjects.discover.clickFieldListItem('bytes');
await PageObjects.discover.expectMissingFieldListItemVisualize('bytes');
});

it('Permalinks shows create short-url button', async () => {
Expand Down Expand Up @@ -365,12 +351,8 @@ export default function({ getPageObjects, getService }: FtrProviderContext) {
it(`shows the visualize button`, async () => {
await PageObjects.common.navigateToApp('discover');
await setDiscoverTimeRange();
await retry.try(async () => {
const hitCount = await PageObjects.discover.getHitCount();
expect(parseInt(hitCount, 10)).to.be.greaterThan(0);
await PageObjects.discover.clickFieldListItem('bytes');
await PageObjects.discover.expectFieldListItemVisualize('bytes');
});
await PageObjects.discover.clickFieldListItem('bytes');
await PageObjects.discover.expectFieldListItemVisualize('bytes');
});
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ export default function({ getPageObjects, getService }: FtrProviderContext) {
const esArchiver = getService('esArchiver');
const config = getService('config');
const spacesService = getService('spaces');
const retry = getService('retry');
const PageObjects = getPageObjects([
'common',
'discover',
Expand Down Expand Up @@ -69,12 +68,8 @@ export default function({ getPageObjects, getService }: FtrProviderContext) {
basePath: '/s/custom_space',
});
await setDiscoverTimeRange();
await retry.try(async () => {
const hitCount = await PageObjects.discover.getHitCount();
expect(parseInt(hitCount, 10)).to.be.greaterThan(0);
await PageObjects.discover.clickFieldListItem('bytes');
await PageObjects.discover.expectFieldListItemVisualize('bytes');
});
await PageObjects.discover.clickFieldListItem('bytes');
await PageObjects.discover.expectFieldListItemVisualize('bytes');
});
});

Expand Down Expand Up @@ -139,12 +134,8 @@ export default function({ getPageObjects, getService }: FtrProviderContext) {
basePath: '/s/custom_space',
});
await setDiscoverTimeRange();
await retry.try(async () => {
const hitCount = await PageObjects.discover.getHitCount();
expect(parseInt(hitCount, 10)).to.be.greaterThan(0);
await PageObjects.discover.clickFieldListItem('bytes');
await PageObjects.discover.expectMissingFieldListItemVisualize('bytes');
});
await PageObjects.discover.clickFieldListItem('bytes');
await PageObjects.discover.expectMissingFieldListItemVisualize('bytes');
});
});

Expand Down

0 comments on commit cc76e78

Please sign in to comment.