-
Notifications
You must be signed in to change notification settings - Fork 33
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
Close #40 Add support for test-containers to be compliant with native engine statements #42
base: master
Are you sure you want to change the base?
Conversation
… engine statements
jpa2ddl-core/src/main/java/com/devskiller/jpa2ddl/DatabaseSchemaProcessor.java
Outdated
Show resolved
Hide resolved
@@ -5,7 +5,12 @@ | |||
/** | |||
* Generation based on setting up embedded database and dumping the schema | |||
*/ | |||
DATABASE, | |||
EMBEDDED_DATABASE, |
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.
Maybe an overkill, but this isn't backward compatible? This enum
is used as part of configuration?
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.
It is, but as we're releasing the stable version I don't have problem with breaking it
} | ||
|
||
private void validateSettings(GeneratorSettings settings) { | ||
if (settings.getAction() == Action.UPDATE) { | ||
if (settings.getOutputPath().exists() && !settings.getOutputPath().isDirectory()) { | ||
throw new IllegalArgumentException("For UPDATE action outputPath must be a directory"); | ||
} | ||
if (settings.getGenerationMode() != GenerationMode.DATABASE) { | ||
if (settings.getGenerationMode() != GenerationMode.EMBEDDED_DATABASE && settings.getGenerationMode() != GenerationMode.CONTAINER_DATABASE) { |
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.
Maybe some flag on GenerationMode
to avoid &&
? Also, the error message below is incorrect
@@ -79,7 +79,6 @@ | |||
<groupId>junit</groupId> | |||
<artifactId>junit</artifactId> | |||
<version>4.13.1</version> | |||
<scope>test</scope> |
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.
…maProcessor.java Co-authored-by: Tomasz Nurkiewicz <[email protected]>
No description provided.