source: josm/trunk/test/unit/org/openstreetmap/josm/testutils/ParallelParameterized.java@ 17275

Last change on this file since 17275 was 14605, checked in by Don-vip, 5 years ago

see #16073 - convert single global test to one test per imagery entry

Slower, but this improves readbility and allows to focus on entries failing for several consecutive tries.

File size: 1.4 KB
Line 
1/**
2 * Copyright 2012-2017 Michael Tamm and other junit-toolbox contributors
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16package org.openstreetmap.josm.testutils;
17
18import org.junit.runners.Parameterized;
19
20/**
21 * An extension of the JUnit {@link Parameterized} runner,
22 * which executes the tests for each parameter set concurrently.
23 * <p>The maximum number of test threads will be the number of
24 * {@link Runtime#availableProcessors() available processors}.
25 *
26 * @author Michael Tamm (junit-toolbox)
27 */
28public class ParallelParameterized extends Parameterized {
29
30 /**
31 * Constructs a new {@code ParallelParameterized}.
32 * @param klass the root of the suite
33 * @throws Throwable in case of error
34 */
35 public ParallelParameterized(Class<?> klass) throws Throwable {
36 super(klass);
37 setScheduler(new ParallelScheduler());
38 }
39}
Note: See TracBrowser for help on using the repository browser.