I tried to run with junit5 with stand alone runner the following command: java -jar ex1/lib/junit-platform-console-standalone-1.6.0-M1.jar --select-directory="./ex1/test"
with the following hierarchy:
.
├── ex1
│ ├── lib
│ │ ├── apiguardian-api-1.1.0.jar
│ │ ├── junit-jupiter-api-5.6.0-M1.jar
│ │ ├── junit-platform-commons-1.6.0-M1.jar
│ │ ├── junit-platform-console-standalone-1.6.0-M1.jar
│ │ └── opentest4j-1.2.0.jar
│ ├── mavnat.iml
│ ├── out
│ │ ├── production
│ │ │ └── mavnat
│ │ │ ├── AVLTree$AVLNode.class
│ │ │ ├── AVLTree.class
│ │ │ ├── AVLTree$DeletionBalancer.class
│ │ │ ├── AVLTree$IAVLNode.class
│ │ │ ├── AVLTree$InsertionBalancer.class
│ │ │ ├── AVLTree$Rotations.class
│ │ │ └── TreePrinter.class
│ │ └── test
│ │ └── mavnat
│ │ ├── ActualAVLTree.class
│ │ ├── ActualAVLTree$IAVLNode.class
│ │ ├── AVLSanitizer.class
│ │ ├── AVLTreeTest.class
│ │ ├── AVLTreeTestExternal.class
│ │ ├── DeletionTest.class
│ │ ├── ExTester$10.class
│ │ ├── ExTester$11.class
│ │ ├── ExTester$12.class
│ │ ├── ExTester$13.class
│ │ ├── ExTester$14.class
│ │ ├── ExTester$1.class
│ │ ├── ExTester$2.class
│ │ ├── ExTester$3.class
│ │ ├── ExTester$4.class
│ │ ├── ExTester$5.class
│ │ ├── ExTester$6.class
│ │ ├── ExTester$7.class
│ │ ├── ExTester$8.class
│ │ ├── ExTester$9.class
│ │ ├── ExTester.class
│ │ ├── InsertionTest.class
│ │ ├── META-INF
│ │ │ └── mavnat.kotlin_module
│ │ ├── RotationsTest.class
│ │ ├── SplitTest.class
│ │ ├── SuccessStatus.class
│ │ ├── TesterUtils.class
│ │ ├── Tests.class
│ │ └── TestUtils.class
│ ├── pro-1.docx
│ ├── src
│ │ ├── AVLTree.java
│ │ └── TreePrinter.java
│ └── test
│ ├── AVLSanitizer.java
│ ├── AVLTreeTestExternal.java
│ ├── AVLTreeTest.java
│ ├── DeletionTest.java
│ ├── InsertionTest.java
│ ├── JoinTest.java
│ ├── RotationsTest.java
│ ├── SplitTest.java
│ └── TestUtils.java
└── ex2
Unfortunately, it seems that Junit launcher doesn't discover the tests.
╷
├─ JUnit Jupiter ✔
└─ JUnit Vintage ✔
Test run finished after 29 ms
[ 2 containers found ]
[ 0 containers skipped ]
[ 2 containers started ]
[ 0 containers aborted ]
[ 2 containers successful ]
[ 0 containers failed ]
[ 0 tests found ]
[ 0 tests skipped ]
[ 0 tests started ]
[ 0 tests aborted ]
[ 0 tests successful ]
[ 0 tests failed ]
Does anyone know why tests aren't found? I would expect all the tests to be run and get info about failed tests.
edit: verbose run:
Thanks for using JUnit! Support its development at https://junit.org/sponsoring
Test plan execution started. Number of static tests: 0
╷
├─ JUnit Jupiter
└─ JUnit Jupiter finished after 7 ms.
├─ JUnit Vintage
└─ JUnit Vintage finished after 2 ms.
Test plan execution finished. Number of all tests: 0
Test run finished after 42 ms
[ 2 containers found ]
[ 0 containers skipped ]
[ 2 containers started ]
[ 0 containers aborted ]
[ 2 containers successful ]
[ 0 containers failed ]
[ 0 tests found ]
[ 0 tests skipped ]
[ 0 tests started ]
[ 0 tests aborted ]
[ 0 tests successful ]
[ 0 tests failed ]