EmbeddedDatabaseBuilder should load data.sql instead of test-data.sql by default [SPR-6020] #10689
Labels
in: core
Issues in core modules (aop, beans, core, context, expression)
type: enhancement
A general enhancement
Milestone
Sam Brannen opened SPR-6020 and commented
The embedded database support in the new jdbc XML namespace is intended to be generic (i.e., not specific to testing), and as such, it resides in the org.springframework.jdbc bundle instead of the test bundle.
By default (i.e., in EmbeddedDatabaseBuilder.buildDefault()), the DDL script is loaded from schema.xml. In contrast, the default name of the DML script is test-data.sql. This is inconsistent and misleading. Consider, for example, that an embedded database is used in a simple application which loads an initial data set (e.g., reference data). Calling this file test-data.sql in such a scenario would be inappropriate.
My recommendation is to rename the default from test-data.sql to data.sql.
Affects: 3.0 M4
Referenced from: commits e56aa91, c802253
The text was updated successfully, but these errors were encountered: