[ 
https://issues.apache.org/jira/browse/CASSANDRA-15508?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17018433#comment-17018433
 ] 

David Capwell commented on CASSANDRA-15508:
-------------------------------------------

Ok, after diving through ant implementation and looking at which processes get 
forked; here is a dump of what I see.

 

1) testclasslist creates a new JVM for each class.  

2) unless you override -Dtest.runner the default is 1; testclasslist runs with 
1 runner so no concurrent tests (in the same container)

3) current model creates a JVM for each method, but does not support 
paramaiterized tests (same method has different names)

4) the test Marcus is working on had one test fail to gossip then the second 
test couldn't start since the port was still open; this looks like a resource 
leak within a single test class.

 

Given this, I do feel that its fair to say that in-jvm dtest tests are expected 
to run within a single JVM for all the tests in a single class; this is also 
how unit tests run.  By also having this requirement, we simplify the build 
since we don't need the in-jvm tasks, since you can just say 
-Dtest.classlistprefix=distributed; this means we don't fragment the build.

 

Without looking at the code, this is what I changed circle ci to do

 

{code}

ant testclasslist -Dtest.classlistfile=<( echo 
"org/apache/cassandra/distributed/test/ReadRepairTest.java" ) 
-Dtest.classlistprefix=distributed

{code}

 

this means that the split and run commands in circle ci can be shared by unit, 
distributed, long, and burn.

> Failing jvm dtest: FailingRepairTest.testFailingMessage
> -------------------------------------------------------
>
>                 Key: CASSANDRA-15508
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-15508
>             Project: Cassandra
>          Issue Type: Bug
>          Components: Test/unit
>            Reporter: Marcus Eriksson
>            Assignee: David Capwell
>            Priority: Normal
>              Labels: pull-request-available
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> It seems we can't run parameterized unit tests with {{ant testsome}}:
> {code}
> $ ant testsome 
> -Dtest.name=org.apache.cassandra.distributed.test.FailingRepairTest 
> -Dtest.methods=testFailingMessage
> ....
> [junit-timeout] Testcase: 
> initializationError(org.junit.runner.manipulation.Filter):    Caused an ERROR
> [junit-timeout] No tests found matching Method 
> testFailingMessage(org.apache.cassandra.distributed.test.FailingRepairTest) 
> from org.junit.internal.requests.ClassRequest@4d95d2a2
> [junit-timeout] java.lang.Exception: No tests found matching Method 
> testFailingMessage(org.apache.cassandra.distributed.test.FailingRepairTest) 
> from org.junit.internal.requests.ClassRequest@4d95d2a2
> [junit-timeout]         at 
> java.lang.reflect.Constructor.newInstance(Constructor.java:423)
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to