mirror of
https://github.com/iflytek/skillhub.git
synced 2026-10-08 03:07:51 +00:00
fix(test): use ddl-auto=create to prevent cross-context table drops
Multiple @SpringBootTest classes with different @MockBean configs cause separate Spring contexts sharing the same H2 in-memory database. With create-drop, one context's shutdown drops tables needed by another, causing "Table not found (this database is empty)" errors.
This commit is contained in:
parent
0e4bc3b766
commit
4a7f021337
1 changed files with 1 additions and 1 deletions
|
|
@ -10,7 +10,7 @@ spring:
|
|||
password:
|
||||
jpa:
|
||||
hibernate:
|
||||
ddl-auto: create-drop
|
||||
ddl-auto: create
|
||||
database-platform: org.hibernate.dialect.H2Dialect
|
||||
flyway:
|
||||
enabled: false
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue