-
-
Notifications
You must be signed in to change notification settings - Fork 4k
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
Applications should not delete entire User records in tests. #26226
Comments
It’s partially implemented. Missing reactive sql and mongodb. |
Since it's related, I recently had to workaround this in my 21-Points Health project. In case others run into this with v8.4.0 and previous, here's a fix: mraible/21-points@caa91ba. |
Cache seems to be influencing in tests. generator-jhipster/generators/spring-boot/generator.ts Lines 289 to 294 in fb2b56d
|
Overview of the issue
Tests removes every User and Authorities in tests making more difficult to implement and test more advanced security based on Users.
Liquibase and any other bootstrapped data are removed.
We should avoid removing Users and Authorities in tests.
generator-jhipster/generators/server/templates/src/test/java/_package_/security/DomainUserDetailsServiceIT.java.ejs
Line 87 in f0cea14
generator-jhipster/generators/server/templates/src/test/java/_package_/web/rest/AccountResourceIT.java.ejs
Line 150 in f0cea14
generator-jhipster/generators/spring-boot/templates/src/test/java/_package_/_entityPackage_/web/rest/UserResourceIT.java.ejs
Line 269 in f0cea14
Related issues
Suggest a Fix
JHipster Version(s)
JHipster configuration
Entity configuration(s)
entityName.json
files generated in the.jhipster
directoryBrowsers and Operating System
The text was updated successfully, but these errors were encountered: