Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mlUnitTest: allow selection of test suites and test cases to run #383

Closed
dmcassel opened this issue Sep 18, 2018 · 4 comments
Closed

mlUnitTest: allow selection of test suites and test cases to run #383

dmcassel opened this issue Sep 18, 2018 · 4 comments
Milestone

Comments

@dmcassel
Copy link
Contributor

Currently the mlUnitTest task runs all test suites. Add parameters to control which suites and test cases are to be run.

@rjrudin
Copy link
Contributor

rjrudin commented Oct 19, 2018

Just making a note that this will require an enhancement to marklogic-unit-test-client - the TestManager class doesn't yet accept a "tests" param to pass along to the REST endpoint.

@grtjn
Copy link

grtjn commented Apr 21, 2021

Another candidate ticket to move to ml-unit-test, I think..

@rjrudin
Copy link
Contributor

rjrudin commented Aug 9, 2023

I am thinking that the following would be helpful:

./gradlew mlUnitTest -Psuite=suite1
./gradlew mlUnitTest -Psuite=suite1 -Ptests=test1,test2

The marklogic-unit-test REST extension already expects for rs:tests to be a comma-delimited string.

We could also support:

./gradlew mlUnitTest -Psuites=suite1,suite2

where ml-gradle uses a delimiter for the suite names. If we do that though, I don't think a user would ever use -Ptests as well as the odds of test names being in multiple suites seems rare. But we could still pass "tests" as long.

The above design means we'd want the following methods added to marklogic-unit-test:

// For the first use case
JUnitTestSuite runSuite(String suite, String commaDelimitedTestNames, the 3 boolean args)

// For the second use case
List<JUnitTestSuite> runSuites(List<String> suites, String commaDelimitedTestNames, the 3 boolean args)

@rjrudin rjrudin added this to the 4.6.0 milestone Aug 10, 2023
@rjrudin
Copy link
Contributor

rjrudin commented Sep 6, 2023

See #668

@rjrudin rjrudin closed this as completed Sep 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants