4
votes

Previously in Grails 2.2.4 when running integration tests the database migration plugin would start up liquibase and read my changelog.xml file and populate the in memory database with my data.

Then my integration tests would query that data and all was well. After upgrading to Grails 2.3.2, the migration scripts no longer run when I start integration tests.

I tried adding:

grails.plugin.databasemigration.autoMigrateScripts = ['RunApp', 'TestApp']

Believing that this would let the migration run during test. This however has not helped.

Is it possible in Grails 2.3.2 to run migration scripts during integration testing? If so how?

1
It seems that you already answered it in the mail list :-) - user800014
I did! I just couldn't answer my own question on here because stackoverflow has like a 24 hour answer your own question thing. - Rob Louie

1 Answers

6
votes

After much searching I have resolved this problem. I eventually found this on the plugin JIRA: http://jira.grails.org/browse/GPDATABASEMIGRATION-160

Turns out this is in fact a bug in the plugin, and that a temporary workaround is to use: grails.plugin.databasemigration.forceAutoMigrate = true

Hopefully this is fixed in the next version of the plugin, until then I hope this helps someone out.