1/** 2 * Copyright (C) 2010 the original author or authors. 3 * See the notice.md file distributed with this work for additional 4 * information regarding copyright ownership. 5 * 6 * Licensed under the Apache License, Version 2.0 (the "License"); 7 * you may not use this file except in compliance with the License. 8 * You may obtain a copy of the License at 9 * 10 * http://www.apache.org/licenses/LICENSE-2.0 11 * 12 * Unless required by applicable law or agreed to in writing, software 13 * distributed under the License is distributed on an "AS IS" BASIS, 14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 * See the License for the specific language governing permissions and 16 * limitations under the License. 17 */ 18 19package com.beust.jcommander.args; 20 21import com.beust.jcommander.Parameter; 22import com.beust.jcommander.internal.Lists; 23 24import java.util.List; 25 26public class CommandLineArgs { 27 28 @Parameter(description = "The XML suite files to run") 29 public List<String> suiteFiles = Lists.newArrayList(); 30 31 @Parameter(names = { "-log", "-verbose" }, description = "Level of verbosity") 32 public Integer verbose; 33 34 @Parameter(names = "-groups", description = "Comma-separated list of group names to be run") 35 public String groups; 36 37 @Parameter(names = "-excludedgroups", description ="Comma-separated list of group names to be " + 38 "run") 39 public String excludedGroups; 40 41 @Parameter(names = "-d", description ="Output directory") 42 public String outputDirectory; 43 44 @Parameter(names = "-junit", description ="JUnit mode") 45 public Boolean junit = Boolean.FALSE; 46 47 @Parameter(names = "-listener", description = "List of .class files or list of class names" + 48 " implementing ITestListener or ISuiteListener") 49 public String listener; 50 51 @Parameter(names = "-methodselectors", description = "List of .class files or list of class " + 52 "names implementing IMethodSelector") 53 public String methodSelectors; 54 55 @Parameter(names = "-objectfactory", description = "List of .class files or list of class " + 56 "names implementing ITestRunnerFactory") 57 public String objectFactory; 58 59 @Parameter(names = "-parallel", description = "Parallel mode (methods, tests or classes)") 60 public String parallelMode; 61 62 @Parameter(names = "-configfailurepolicy", description = "Configuration failure policy (skip or continue)") 63 public String configFailurePolicy; 64 65 @Parameter(names = "-threadcount", description = "Number of threads to use when running tests " + 66 "in parallel") 67 public Integer threadCount; 68 69 @Parameter(names = "-dataproviderthreadcount", description = "Number of threads to use when " + 70 "running data providers") 71 public Integer dataProviderThreadCount; 72 73 @Parameter(names = "-suitename", description = "Default name of test suite, if not specified " + 74 "in suite definition file or source code") 75 public String suiteName; 76 77 @Parameter(names = "-testname", description = "Default name of test, if not specified in suite" + 78 "definition file or source code") 79 public String testName; 80 81 @Parameter(names = "-reporter", description = "Extended configuration for custom report listener") 82 public String reporter; 83 84 /** 85 * Used as map key for the complete list of report listeners provided with the above argument 86 */ 87 @Parameter(names = "-reporterslist") 88 public String reportersList; 89 90 @Parameter(names = "-usedefaultlisteners", description = "Whether to use the default listeners") 91 public String useDefaultListeners = "true"; 92 93 @Parameter(names = "-skipfailedinvocationcounts") 94 public Boolean skipFailedInvocationCounts; 95 96 @Parameter(names = "-testclass", description = "The list of test classes") 97 public String testClass; 98 99 @Parameter(names = "-testnames", description = "The list of test names to run") 100 public String testNames; 101 102 @Parameter(names = "-testjar", description = "") 103 public String testJar; 104 105 @Parameter(names = "-testRunFactory", description = "") 106 public String testRunFactory; 107 108 @Parameter(names = "-port", description = "The port") 109 public Integer port; 110 111 @Parameter(names = "-host", description = "The host") 112 public String host; 113 114 @Parameter(names = "-master", description ="Host where the master is") 115 public String master; 116 117 @Parameter(names = "-slave", description ="Host where the slave is") 118 public String slave; 119 120} 121