RFR: Fix @library tags in jtreg tests

Maurizio Cimadamore mcimadamore at openjdk.java.net
Thu Apr 7 14:14:40 UTC 2022


On Thu, 7 Apr 2022 11:40:21 GMT, Maurizio Cimadamore <mcimadamore at openjdk.org> wrote:

> The `@library` tags in jtreg tests are wrong. According to the tag specification here:
> 
> https://openjdk.java.net/jtreg/tag-spec.html
> 
> If an absolute path is used in combination with `@library`, the path should be interpreted as either relative to the test root (e.g. test/), or relative to an external root path (specified with a property in TEST.ROOT). Since we're not using any property, it follows that the library path should be relative to `test/` - which means `/lib` is the correct choice here, not `/test/lib`.
> 
> (I discovered this when using the jtreg plugin [1] to run the jextract tests - these bad `@library` tags were causing a crash in the plugin; of course the plugin should be fixed - but the tags in the tests should be fixed as well).
> 
> [1] - https://github.com/openjdk/jtreg/tree/master/plugins/idea

I ended up completely dropping jtreg test headers from all tests under test/java - as those tests are recognized as part of a TestNG folder by jtreg - as such the jtreg test header is ignored.

-------------

PR: https://git.openjdk.java.net/jextract/pull/16


More information about the jextract-dev mailing list