RFR: Re-arrange test directory structure [v2]

Athijegannathan Sundararajan sundar at openjdk.java.net
Thu Apr 14 03:55:18 UTC 2022


On Wed, 13 Apr 2022 21:03:09 GMT, Maurizio Cimadamore <mcimadamore at openjdk.org> wrote:

>> Looking more at jextract tests, when we moved things in the standalone repo, few things went wrong. For instance, `TestSplit` cannot be executed right now, because it would need to be ran with some custom JDK properties. But since it's now part of a testng test structure, that is not possible.
>> 
>> We'd need to move TestSplit in a different folder, but if we do that we have a problem, in that TestSplit depends on the TestUtils and JextractToolRunner helpers.
>> 
>> This patch moves all the helper classes (JextractToolRunner, TestUtils, JextractAPITestBase) in the `testlib` package under the `test/lib` folder.
>> 
>> Then, this patch restructures the test folder, as follows:
>> 
>> * the `java` folder is renamed to `testng` - all testng test w/o jtreg header live here
>> * the `generator` folder is moved under a new folder called `jtreg`; under this new folder we find tests with regular jtreg header
>> 
>> With all this, we can now add a TEST.properties file under `test/testng` which contains a pointer to the lib folder that should be used by testng tests.
>> 
>> And, we can finally move TestSplit under `test/jtreg`, and add the jtreg test header we need to be able to run this correctly.
>
> Maurizio Cimadamore has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains three commits:
> 
>  - Merge branch 'master' into test_libs_move
>  - Revamp test directory structure
>  - Move JextractToolRunner and JextractApiTestBase in lib folder

latest change looks good to me.

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

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


More information about the jextract-dev mailing list