Skip to content
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

[Obs Onboarding] Migrate API test to deployment agnostic framework #211548

Conversation

mykolaharmash
Copy link
Contributor

@mykolaharmash mykolaharmash commented Feb 18, 2025

Closes 206953

This change migrates mosts of the Obs Onboarding API tests to the deployment agnostic framework. A few tests has to be still left in the deployment-specific setup because they require a custom roles which are not supported in the deployment agnostic setup for serverless-oblt.

@mykolaharmash mykolaharmash requested review from a team as code owners February 18, 2025 11:25
@botelastic botelastic bot added the ci:project-deploy-observability Create an Observability project label Feb 18, 2025
Copy link
Contributor

🤖 GitHub comments

Expand to view the GitHub comments

Just comment with:

  • /oblt-deploy : Deploy a Kibana instance using the Observability test environments.
  • run docs-build : Re-trigger the docs validation. (use unformatted text in the comment!)

@mykolaharmash mykolaharmash added release_note:skip Skip the PR/issue when compiling release notes backport:skip This commit does not require backporting labels Feb 18, 2025
@mykolaharmash mykolaharmash force-pushed the 206953-observability-onboarding-meta-migrate-onboarding-api-integration-tests-to-deployment-agnostic branch 2 times, most recently from c91e0fd to e57b6fb Compare February 18, 2025 11:58
Copy link
Member

@dmlemeshko dmlemeshko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, just one nit

Comment on lines 19 to 26
before(async () => {
viewerClient = await roleScopedSupertest.getSupertestWithRoleScope('viewer', {
withInternalHeaders: true,
});
adminClient = await roleScopedSupertest.getSupertestWithRoleScope('admin', {
withInternalHeaders: true,
});
});
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we need to invalidate api keys after tests executed:

    after(async () => {
      viewerClient.destroy();
      adminClient.destroy();
    });

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe good to rename to viewClientWithAPIKey and adminClientWithAPIKey for visiblity

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! Renamed the variables and added after

@mykolaharmash mykolaharmash force-pushed the 206953-observability-onboarding-meta-migrate-onboarding-api-integration-tests-to-deployment-agnostic branch from e57b6fb to 4903a06 Compare February 18, 2025 15:17
@elasticmachine
Copy link
Contributor

⏳ Build in-progress

  • Buildkite Build
  • Commit: f0acc53
  • Kibana Serverless Image: docker.elastic.co/kibana-ci/kibana-serverless:pr-211548-f0acc53039be

History

@awahab07 awahab07 self-requested a review February 19, 2025 10:24
Copy link
Contributor

@awahab07 awahab07 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

Thanks for migrating the API tests to Deployment Agnostic.

@mykolaharmash mykolaharmash merged commit a015f74 into elastic:main Feb 19, 2025
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:skip This commit does not require backporting ci:project-deploy-observability Create an Observability project release_note:skip Skip the PR/issue when compiling release notes v9.1.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Observability Onboarding] Meta - Migrate Onboarding API Integration Tests to Deployment Agnostic
5 participants