Commit b2a9810
authored
Introduce junit-platform-suite-engine (#2416)
Implements a test engine that allows declarative execution of test suites using
the `@Suite` annotation.
Internally the Suite Engine uses the JUnit Platform Launcher. The engine works
adding the test descriptors of the discovered engines and tests as children to its
own test descriptor.
```java
package org.junit.platform.suite;
import org.junit.platform.suite.api.SelectPackages;
@suite
@SelectPackages("org.junit.suite.testcases")
class SelectPackageSuite {
}
```
Is equivalent to:
```java
import org.junit.platform.engine.discovery.DiscoverySelectors;
import org.junit.platform.launcher.Launcher;
import org.junit.platform.launcher.LauncherDiscoveryRequest;
import org.junit.platform.launcher.core.LauncherDiscoveryRequestBuilder;
import org.junit.platform.launcher.core.LauncherFactory;
public class Main {
public static void main(String[] args) {
Launcher launcher = LauncherFactory.create();
LauncherDiscoveryRequest request = LauncherDiscoveryRequestBuilder.request()
.selectors(DiscoverySelectors.selectPackage("org.junit.suite.testcases"))
.build();
launcher.execute(request);
}
}
```
Resolves #744.1 parent 9c4da09 commit b2a9810
File tree
92 files changed
+2794
-388
lines changed- documentation
- src
- docs/asciidoc
- release-notes
- user-guide
- test/java/example
- junit-platform-commons/src/module/org.junit.platform.commons
- junit-platform-engine/src/main/java/org/junit/platform/engine
- discovery
- junit-platform-launcher/src/main/java/org/junit/platform/launcher/core
- junit-platform-runner
- src
- main/java/org/junit/platform/runner
- module/org.junit.platform.runner
- junit-platform-suite-api
- src
- main/java/org/junit/platform/suite/api
- module/org.junit.platform.suite.api
- junit-platform-suite-commons
- src
- main/java/org/junit/platform/suite/commons
- module/org.junit.platform.suite.commons
- test/java/org/junit/platform/suite/commons
- junit-platform-suite-engine
- src
- main
- java/org/junit/platform/suite/engine
- resources/META-INF/services
- module/org.junit.platform.suite.engine
- testFixtures/java/org/junit/platform/suite/engine
- testcases
- testsuites
- test/java/org/junit/platform/suite/engine
- junit-platform-suite
- src/module/org.junit.platform.suite
- platform-tests/src/test/java/org/junit/platform
- engine
- runner
- platform-tooling-support-tests
- projects/jar-describe-module
- src/test/java/platform/tooling/support
- tests
- src
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
92 files changed
+2794
-388
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
42 | 42 | | |
43 | 43 | | |
44 | 44 | | |
| 45 | + | |
45 | 46 | | |
| 47 | + | |
| 48 | + | |
46 | 49 | | |
47 | 50 | | |
48 | 51 | | |
| |||
76 | 79 | | |
77 | 80 | | |
78 | 81 | | |
| 82 | + | |
| 83 | + | |
79 | 84 | | |
80 | 85 | | |
81 | 86 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
41 | 41 | | |
42 | 42 | | |
43 | 43 | | |
| 44 | + | |
44 | 45 | | |
45 | 46 | | |
46 | 47 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
43 | 43 | | |
44 | 44 | | |
45 | 45 | | |
46 | | - | |
| 46 | + | |
47 | 47 | | |
| 48 | + | |
48 | 49 | | |
49 | 50 | | |
50 | 51 | | |
| |||
Lines changed: 3 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
45 | 45 | | |
46 | 46 | | |
47 | 47 | | |
48 | | - | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
49 | 51 | | |
50 | 52 | | |
51 | 53 | | |
| |||
Lines changed: 2 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| 6 | + | |
| 7 | + | |
6 | 8 | | |
7 | 9 | | |
8 | 10 | | |
| |||
Lines changed: 29 additions & 12 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
50 | 50 | | |
51 | 51 | | |
52 | 52 | | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
53 | 57 | | |
54 | 58 | | |
55 | | - | |
56 | | - | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
57 | 64 | | |
58 | 65 | | |
59 | 66 | | |
| |||
148 | 155 | | |
149 | 156 | | |
150 | 157 | | |
| 158 | + | |
151 | 159 | | |
| 160 | + | |
| 161 | + | |
152 | 162 | | |
153 | 163 | | |
154 | 164 | | |
| |||
173 | 183 | | |
174 | 184 | | |
175 | 185 | | |
176 | | - | |
177 | | - | |
| 186 | + | |
| 187 | + | |
178 | 188 | | |
179 | | - | |
| 189 | + | |
180 | 190 | | |
181 | 191 | | |
182 | 192 | | |
183 | 193 | | |
184 | | - | |
| 194 | + | |
185 | 195 | | |
186 | 196 | | |
187 | 197 | | |
| |||
190 | 200 | | |
191 | 201 | | |
192 | 202 | | |
193 | | - | |
| 203 | + | |
194 | 204 | | |
195 | 205 | | |
196 | 206 | | |
197 | 207 | | |
198 | | - | |
199 | | - | |
200 | | - | |
| 208 | + | |
| 209 | + | |
201 | 210 | | |
202 | | - | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
203 | 220 | | |
204 | 221 | | |
205 | | - | |
| 222 | + | |
206 | 223 | | |
207 | 224 | | |
Lines changed: 45 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
Lines changed: 3 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
77 | 77 | | |
78 | 78 | | |
79 | 79 | | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
80 | 83 | | |
81 | 84 | | |
82 | 85 | | |
| |||
Lines changed: 1 addition & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
630 | 630 | | |
631 | 631 | | |
632 | 632 | | |
| 633 | + | |
633 | 634 | | |
634 | 635 | | |
635 | 636 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
0 commit comments