-
Notifications
You must be signed in to change notification settings - Fork 282
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
Move REST API tests into integration tests (Part 1) #4153
Move REST API tests into integration tests (Part 1) #4153
Conversation
bbdfd76
to
d194185
Compare
src/integrationTest/java/org/opensearch/security/api/AbstractApiIntegrationTest.java
Outdated
Show resolved
Hide resolved
- Added hidden/reserved fields for TestSecurityConfig.User, TestSecurityConfig.Role - Moved RolesMapping class into TestSecurityConfig - Added ActionGroup class in TestSecurityConfig - LocalOpenSearchCluster now always delete config folders when any test is over - Added bodyAsJsonNode in the HttpResponse class Signed-off-by: Andrey Pleskach <[email protected]>
e9ca7ad
to
78be229
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #4153 +/- ##
==========================================
- Coverage 66.15% 66.04% -0.12%
==========================================
Files 301 301
Lines 21708 21709 +1
Branches 3506 3506
==========================================
- Hits 14362 14337 -25
- Misses 5584 5610 +26
Partials 1762 1762
|
098e9f7
to
e79c158
Compare
e79c158
to
9d3fab7
Compare
9b87bae
to
2fdaf28
Compare
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.
Overall looks good to me. Thanks @willyborankin
src/integrationTest/java/org/opensearch/security/ConfigurationFiles.java
Outdated
Show resolved
Hide resolved
src/integrationTest/java/org/opensearch/security/ConfigurationFiles.java
Outdated
Show resolved
Hide resolved
src/integrationTest/java/org/opensearch/security/api/AbstractApiIntegrationTest.java
Show resolved
Hide resolved
src/integrationTest/java/org/opensearch/test/framework/TestSecurityConfig.java
Show resolved
Hide resolved
2fdaf28
to
b38fe15
Compare
Hi, @scrawfor99 than you for the review. I addressed your comments |
10ee660
to
cec6278
Compare
cec6278
to
e0191cc
Compare
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.
Lets get this merged, make follow up PRs if desired
src/integrationTest/java/org/opensearch/security/api/AccountRestApiIntegrationTest.java
Outdated
Show resolved
Hide resolved
Added test: - DefaultApiAvailabilityIntegrationTest Moved tests: - FlushCacheApiTest part of DefaultApiAvailabilityIntegrationTest - AccountApiTest as AccountRestApiIntegrationTest Tests with the Legacy prefix removed since new tests use randomization for paths Signed-off-by: Andrey Pleskach <[email protected]>
e0191cc
to
ec26a2f
Compare
a6b04ae
into
opensearch-project:main
The backport to
To backport manually, run these commands in your terminal: # Navigate to the root of your repository
cd $(git rev-parse --show-toplevel)
# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add ../.worktrees/security/backport-2.x 2.x
# Navigate to the new working tree
pushd ../.worktrees/security/backport-2.x
# Create a new branch
git switch --create backport/backport-4153-to-2.x
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 a6b04ae751c5233aeaf50ff63a918fccb58caa31
# Push it to GitHub
git push --set-upstream origin backport/backport-4153-to-2.x
# Go back to the original working tree
popd
# Delete the working tree
git worktree remove ../.worktrees/security/backport-2.x Then, create a pull request where the |
…pensearch-project#4153) Signed-off-by: Andrey Pleskach <[email protected]>
…ct#4153) Signed-off-by: Andrey Pleskach <[email protected]>
…4153) (#4302) Signed-off-by: Andrey Pleskach <[email protected]>
Description
REST API tests refactoring. First part of moving REST API tests into
integrationTests
.Added test:
DefaultApiAvailabilityIntegrationTest
Moved tests:
FlushCacheApiTest
part ofDefaultApiAvailabilityIntegrationTest
AccountApiTest
asAccountRestApiIntegrationTest
Tests with the
Legacy
prefix removed since new tests use randomization for pathsTesting
[Please provide details of testing done: unit testing, integration testing and manual testing]
Check List
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.