Inside src/test/resources there is an arquillian.xml file that has to be expanded by gradle at processTestResources task. When a test is run from within vs code, this doesn't happen and the resource file is used as is. This triggers an error from Junit that basically says that some property is invalid (because it's expanded, i.e. junit see it as ${somePropToExpand}).
Same thing occurs when arquillian.xml is auto generated by a plugin - a gradle plugin can auto create it and put it directly in the buildDir/resources/test dir. When a test is run from within vs code, basically the file is invisible to vs code.
Both of these problems can be corrected by having a:
sourceSets {
test {
resources {
srcDirs += "$buildDir/resources/test"
}
}
}
But that by itself creates a new set of problems for the build.
Inside
src/test/resourcesthere is anarquillian.xmlfile that has to be expanded by gradle atprocessTestResourcestask. When a test is run from within vs code, this doesn't happen and the resource file is used as is. This triggers an error from Junit that basically says that some property is invalid (because it's expanded, i.e. junit see it as${somePropToExpand}).Same thing occurs when arquillian.xml is auto generated by a plugin - a gradle plugin can auto create it and put it directly in the buildDir/resources/test dir. When a test is run from within vs code, basically the file is invisible to vs code.
Both of these problems can be corrected by having a:
sourceSets { test { resources { srcDirs += "$buildDir/resources/test" } } }But that by itself creates a new set of problems for the build.