[graalvm-dev] mx build problem

Gilles Duboscq gilles.m.duboscq at oracle.com
Thu Oct 8 03:26:11 PDT 2020


Given the current dependencies of `com.oracle.svm.test` and the code that is in there i guess it's not really intended to have any kind of whitebox unittests in there:
those tests should likely only use/test the SDK API, not the SVM internals.

The issue is likely that by adding the `com.oracle.svm.configure` dependency a large graph of transitive dependencies have been added to `SVM_TESTS`.
A quick workaround might be to add `SVM_CONFIGURE` in the `distDependencies` of `SVM_TESTS`. However that might have implications when running the tests.

 Gilles

On 07/10/2020 14:32, Pascal Gillet wrote:
> Hi Folks,
> 
> I try to implement a JUnit test for com.oracle.svm.configure.config.ResourceConfiguration class in substratevm.
> 
> I added my test class in module com.oracle.svm.test, and added a mx dependency on com.oracle.svm.configure in mx.substratevm/suite.py:
> 
> "com.oracle.svm.test": {
>     "subDir": "src",
> "sourceDirs": ["src"],
> "dependencies": [
>         "mx:JUNIT_TOOL",
> "sdk:GRAAL_SDK",
> "com.oracle.svm.configure",
> ],
> "checkstyle": "com.oracle.svm.core",
> "workingSets": "SVM",
> "annotationProcessors": [
>         "compiler:GRAAL_PROCESSOR",
> ],
> "javaCompliance": "8+",
> "spotbugs": "false",
> }
> 
> 
> Is the module com.oracle.svm.test the right place to implement such a test, or should I create a dedicated test module like com.oracle.svm.configure.test ?
> 
> When I run 'mx build', I got the following error message:
> 
> File "/home/pascal/Workbench/Projects/graal/substratevm/mx.substratevm/suite.py", line 1124 in definition of SVM_TESTS:
> Distribution must explicitly specify a dependency on org.graalvm.libgraal as it has overlays. SVM_TESTS
> 
> Am I missing something?
> 
> Many thanks,
> 
> Pascal GILLET
> 
> _______________________________________________
> GraalVM-Dev mailing list
> GraalVM-Dev at oss.oracle.com
> https://oss.oracle.com/mailman/listinfo/graalvm-dev
> 



More information about the GraalVM-Dev mailing list