Skip to content

Commit

Permalink
update tests and FTR
Browse files Browse the repository at this point in the history
  • Loading branch information
saarikabhasi committed Apr 30, 2024
1 parent 323136f commit f54bf1f
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -83,9 +83,13 @@ describe('<Overview />', () => {
const { getByRole } = render(<Overview />);
expect(getByRole('heading', { name: 'Build your first search query' })).toBeDefined();
});
test('transform data', () => {
test('preprocess data', () => {
const { getByRole } = render(<Overview />);
expect(getByRole('heading', { name: 'Transform and enrich your data' })).toBeDefined();
expect(
getByRole('heading', {
name: 'Preprocess your data by enriching, transforming or filtering with pipelines',
})
).toBeDefined();
});
test("what's next?", () => {
const { getByRole } = render(<Overview />);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,14 +79,22 @@ export function SvlSearchLandingPageProvider({ getService }: FtrProviderContext)
},
},
pipeline: {
async click() {
async createPipeline() {
await testSubjects.click('create-a-pipeline-button');
},
async expectNavigateToCreatePipelinePage() {
expect(await browser.getCurrentUrl()).contain(
'/app/management/ingest/ingest_pipelines/create'
);
},
async managePipeline() {
await testSubjects.click('manage-pipeline-button');
},
async expectNavigateToManagePipelinePage() {
expect(await browser.getCurrentUrl()).contain(
'/app/management/ingest/ingest_pipelines'
);
},
},
};
}
Original file line number Diff line number Diff line change
Expand Up @@ -94,9 +94,13 @@ export default function ({ getPageObjects, getService }: FtrProviderContext) {

describe('Pipeline creation', async () => {
it('can redirect to the pipeline creation index page', async () => {
await pageObjects.svlSearchLandingPage.pipeline.click();
await pageObjects.svlSearchLandingPage.pipeline.createPipeline();
await pageObjects.svlSearchLandingPage.pipeline.expectNavigateToCreatePipelinePage();
});
it('can redirect to the manage pipelines page', async () => {
await pageObjects.svlSearchLandingPage.pipeline.managePipeline();
await pageObjects.svlSearchLandingPage.pipeline.expectNavigateToManagePipelinePage();
});
});
});
}

0 comments on commit f54bf1f

Please sign in to comment.