-
Notifications
You must be signed in to change notification settings - Fork 8.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Serverless] Add navigation functional tests #161856
Conversation
…to d/2023-07-11-chrome-e2e
…rome-e2e # Conflicts: # x-pack/test_serverless/tsconfig.json
Pinging @elastic/appex-sharedux (Team:SharedUX) |
|
||
it('breadcrumbs reflect navigation state', async () => { | ||
await svlCommonNavigation.breadcrumbs.expectExists(); | ||
// TODO: use `deepLinkId` instead of `text`, once security deep links are available in @kbn/core-chrome-browser |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We are already setting the navigationTree
, should we do something else?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This isn't required, but nice to have. For example, observability and search have their deep link ids types in a separate package so that we can use it for type safety and auto complete in different places.
export type AppDeepLinkId = | |
| AnalyticsDeepLink | |
| DevToolsLink | |
| MlLink | |
| ManagementLink | |
| SearchLink | |
| ObservabilityLink; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
search changes LGTM, thanks for adding these tests!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Observability changes are good to go, LGTM 👍🏼
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome work @Dosant ! I really like the helpers 👍
Left small comments, no blockers.
x-pack/test_serverless/functional/page_objects/svl_common_navigation.ts
Outdated
Show resolved
Hide resolved
}, | ||
|
||
// helper to assert that the page did not reload | ||
async createNoPageReloadCheck() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very nice helper! 🎉
x-pack/test_serverless/functional/test_suites/observability/navigation.ts
Outdated
Show resolved
Hide resolved
…rome-e2e # Conflicts: # x-pack/plugins/serverless_observability/public/components/side_navigation/index.tsx
💚 Build Succeeded
Metrics [docs]Page load bundle
History
To update your PR or re-run it, just comment with: cc @Dosant |
## Summary close elastic#160011 This PR adds helpers for testing serverless specific navigation. There are helpers for sidenav, breadcrumbs, global search, recent items, logo, checking that no page reload happened during nav. This PR also adds some serverless specific navigation tests. The should serve as a navigation smoke check and testing helpers example. Solution teams can improve them as they see fit.
Summary
close #160011
This PR adds helpers for testing serverless specific navigation. There are helpers for sidenav, breadcrumbs, global search, recent items, logo, checking that no page reload happened during nav.
This PR also adds some serverless specific navigation tests. The should serve as a navigation smoke check and testing helpers example. Solution teams can improve them as they see fit.