Fortunately this works perfectly well when using Gradle straight from a shell, it's just in the IDE (I'm using STS 3.2.0.M1) that tokens do not get replaced.
I attach a link to a sample project which demonstrates the issue:
http://dl.dropbox.com/u/123005133/gra...
Running _./gradlew clean build_ from a shell should yield a successful build in which the project's single test, in _PropertySlurperTest_, will pass. However if this same project is imported as a Gradle project in to STS/ Eclipse then running the test in _PropertySlurperTest_ will fail with the following message:
Assertion failed:
assert expectedPropertyValue == propertySlurper.getProperty("myProperty")
| | | |
"@expectedTestResult@"| | "@myProperty@"
| com.eddgrant.PropertyReader@687bc899
false
From what I can tell the filtering code that I have written in the _build.gradle_ is not being executed when the _processResources_ and _processTestResources_ tasks are invoked in the IDE. I'm guessing however that the tasks are being invoked as the property files both in _src/main/resources and src/test/resources_ are being copied over to the bin directory.
Would be most grateful if anyone knows why this is happening. Particularly for any steer as to whether I'm doing something wrong or whether this is actually a bug in gradle-eclipse?
If you need any further info to understand the problem please don't hesitate to ask.
Many thanks.
Loading Profile...

Twitter,
Facebook, or email.

