@TestFactory
	@Execution(ExecutionMode.CONCURRENT)
	public List<DynamicNode> runtimeTests() {
		List<DynamicNode> result = new ArrayList<>();

		for (String group : testDescriptors.keySet()) {
			ArrayList<DynamicNode> descriptorTests = new ArrayList<>();
			RuntimeTestDescriptor[] descriptors = testDescriptors.get(group);
			for (RuntimeTestDescriptor descriptor : descriptors) {
				descriptorTests.add(dynamicTest(descriptor.name, descriptor.uri, () -> {
					try (RuntimeRunner runner = createRuntimeRunner()) {
						String errorMessage = test(descriptor, runner);
						if (errorMessage != null) {
							runner.setSaveTestDir(true);
							fail(joinLines("Test: " + descriptor.name + "; " + errorMessage, "Test directory: " + runner.getTempDirPath()));
						}
					}
				}));
			}

			Path descriptorGroupPath = Paths.get(RuntimeTestUtils.resourcePath.toString(), "descriptors", group);
			result.add(dynamicContainer(group, descriptorGroupPath.toUri(), Arrays.stream(descriptorTests.toArray(new DynamicNode[0]))));
		}

		return result;
	}
This class represents runtime tests for specified runtime.
 It pulls data from {@link RuntimeTestDescriptor} and uses junit to trigger tests.
 The only functionality needed to execute a test is defined in {@link RuntimeRunner}.
 All the various test rig classes derived from this one.
 E.g., see {@link JavaRuntimeTests}.
runtime-testsuite/test/org/antlr/v4/test/runtime/RuntimeTests.java