grails / grails-gradle-plugin

Apache License 2.0
6 stars 9 forks source link

plugins can overwrite message bundles in integration tests #235

Closed matthijsbierman closed 11 months ago

matthijsbierman commented 1 year ago

OS: macOS Sonoma 14.0 (23A344) JDK: Eclipse Temurin JDK 17.0.6+10 (aarch64) Grails: 6.0.0 installed through SDKman

The order of resources on the classpath from plugins seems to have changed between version 5.3.0 and 6.0.0. Before the project resources came first, but now the plugins come first. This causes integration tests to load message bundles from the plugin, instead of the application's grails-app/i18n/ folder.

Example project with reproduction here: https://github.com/matthijsbierman/grails6-i18n-bug

If you remove the dependency on the mail plugin, the test will pass. Downgrading to implementation("org.grails:grails-gradle-plugin:5.3.0") in buildSrc/build.gradle will also result in a passing test.