147 lines
6.7 KiB
Diff
147 lines
6.7 KiB
Diff
# HG changeset patch
|
|
# User mbooth <mat.booth@redhat.com>
|
|
# Date 1511260104 0
|
|
# Tue Nov 21 10:28:24 2017 +0000
|
|
# Node ID 731399becd960a450cf277916308dac52c1e2e93
|
|
# Parent 7ff584954008f5dc877c590df5d902a0022f7456
|
|
Upgrade to latest jopt-simple
|
|
|
|
diff --git a/jmh-core/pom.xml b/jmh-core/pom.xml
|
|
--- a/jmh-core/pom.xml
|
|
+++ b/jmh-core/pom.xml
|
|
@@ -60,7 +60,7 @@
|
|
<dependency>
|
|
<groupId>net.sf.jopt-simple</groupId>
|
|
<artifactId>jopt-simple</artifactId>
|
|
- <version>4.6</version>
|
|
+ <version>5.0.4</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.apache.commons</groupId>
|
|
diff --git a/jmh-core/src/main/java/org/openjdk/jmh/runner/options/IntegerValueConverter.java b/jmh-core/src/main/java/org/openjdk/jmh/runner/options/IntegerValueConverter.java
|
|
--- a/jmh-core/src/main/java/org/openjdk/jmh/runner/options/IntegerValueConverter.java
|
|
+++ b/jmh-core/src/main/java/org/openjdk/jmh/runner/options/IntegerValueConverter.java
|
|
@@ -66,7 +66,7 @@
|
|
}
|
|
|
|
@Override
|
|
- public Class<Integer> valueType() {
|
|
+ public Class<? extends Integer> valueType() {
|
|
return TO_INT_CONVERTER.valueType();
|
|
}
|
|
|
|
diff --git a/jmh-core/src/main/java/org/openjdk/jmh/runner/options/ThreadsValueConverter.java b/jmh-core/src/main/java/org/openjdk/jmh/runner/options/ThreadsValueConverter.java
|
|
--- a/jmh-core/src/main/java/org/openjdk/jmh/runner/options/ThreadsValueConverter.java
|
|
+++ b/jmh-core/src/main/java/org/openjdk/jmh/runner/options/ThreadsValueConverter.java
|
|
@@ -42,7 +42,7 @@
|
|
}
|
|
|
|
@Override
|
|
- public Class<Integer> valueType() {
|
|
+ public Class<? extends Integer> valueType() {
|
|
return IntegerValueConverter.POSITIVE.valueType();
|
|
}
|
|
|
|
diff --git a/jmh-core/src/test/java/org/openjdk/jmh/runner/options/TestOptions.java b/jmh-core/src/test/java/org/openjdk/jmh/runner/options/TestOptions.java
|
|
--- a/jmh-core/src/test/java/org/openjdk/jmh/runner/options/TestOptions.java
|
|
+++ b/jmh-core/src/test/java/org/openjdk/jmh/runner/options/TestOptions.java
|
|
@@ -244,7 +244,7 @@
|
|
new CommandLineOptions("-t", "0");
|
|
Assert.fail();
|
|
} catch (CommandLineOptionException e) {
|
|
- Assert.assertEquals("Cannot parse argument '0' of option ['t']. The given value 0 should be positive", e.getMessage());
|
|
+ Assert.assertEquals("Cannot parse argument '0' of option t. The given value 0 should be positive", e.getMessage());
|
|
}
|
|
}
|
|
|
|
@@ -264,7 +264,7 @@
|
|
new CommandLineOptions("-t", "-1");
|
|
Assert.fail();
|
|
} catch (CommandLineOptionException e) {
|
|
- Assert.assertEquals("Cannot parse argument '-1' of option ['t']. The given value -1 should be positive", e.getMessage());
|
|
+ Assert.assertEquals("Cannot parse argument '-1' of option t. The given value -1 should be positive", e.getMessage());
|
|
}
|
|
}
|
|
|
|
@@ -274,7 +274,7 @@
|
|
new CommandLineOptions("-t", "-42");
|
|
Assert.fail();
|
|
} catch (CommandLineOptionException e) {
|
|
- Assert.assertEquals("Cannot parse argument '-42' of option ['t']. The given value -42 should be positive", e.getMessage());
|
|
+ Assert.assertEquals("Cannot parse argument '-42' of option t. The given value -42 should be positive", e.getMessage());
|
|
}
|
|
}
|
|
|
|
@@ -337,7 +337,7 @@
|
|
new CommandLineOptions("-tg", "-1,-2");
|
|
Assert.fail();
|
|
} catch (CommandLineOptionException e) {
|
|
- Assert.assertEquals("Cannot parse argument '-1' of option ['tg']. The given value -1 should be non-negative", e.getMessage());
|
|
+ Assert.assertEquals("Cannot parse argument '-1' of option tg. The given value -1 should be non-negative", e.getMessage());
|
|
}
|
|
}
|
|
|
|
@@ -395,7 +395,7 @@
|
|
new CommandLineOptions("-wi", "-1");
|
|
Assert.fail();
|
|
} catch (CommandLineOptionException e) {
|
|
- Assert.assertEquals("Cannot parse argument '-1' of option ['wi']. The given value -1 should be non-negative", e.getMessage());
|
|
+ Assert.assertEquals("Cannot parse argument '-1' of option wi. The given value -1 should be non-negative", e.getMessage());
|
|
}
|
|
}
|
|
|
|
@@ -439,7 +439,7 @@
|
|
new CommandLineOptions("-i", "0");
|
|
Assert.fail();
|
|
} catch (CommandLineOptionException e) {
|
|
- Assert.assertEquals("Cannot parse argument '0' of option ['i']. The given value 0 should be positive", e.getMessage());
|
|
+ Assert.assertEquals("Cannot parse argument '0' of option i. The given value 0 should be positive", e.getMessage());
|
|
}
|
|
}
|
|
|
|
@@ -515,7 +515,7 @@
|
|
new CommandLineOptions("-opi", "0");
|
|
Assert.fail();
|
|
} catch (CommandLineOptionException e) {
|
|
- Assert.assertEquals("Cannot parse argument '0' of option ['opi']. The given value 0 should be positive", e.getMessage());
|
|
+ Assert.assertEquals("Cannot parse argument '0' of option opi. The given value 0 should be positive", e.getMessage());
|
|
}
|
|
}
|
|
|
|
@@ -559,7 +559,7 @@
|
|
new CommandLineOptions("-f", "-1");
|
|
Assert.fail();
|
|
} catch (CommandLineOptionException e) {
|
|
- Assert.assertEquals("Cannot parse argument '-1' of option ['f']. The given value -1 should be non-negative", e.getMessage());
|
|
+ Assert.assertEquals("Cannot parse argument '-1' of option f. The given value -1 should be non-negative", e.getMessage());
|
|
}
|
|
}
|
|
|
|
@@ -598,7 +598,7 @@
|
|
new CommandLineOptions("-wf", "-1");
|
|
Assert.fail();
|
|
} catch (CommandLineOptionException e) {
|
|
- Assert.assertEquals("Cannot parse argument '-1' of option ['wf']. The given value -1 should be non-negative", e.getMessage());
|
|
+ Assert.assertEquals("Cannot parse argument '-1' of option wf. The given value -1 should be non-negative", e.getMessage());
|
|
}
|
|
}
|
|
|
|
@@ -678,7 +678,7 @@
|
|
new CommandLineOptions("-bs", "0");
|
|
Assert.fail();
|
|
} catch (CommandLineOptionException e) {
|
|
- Assert.assertEquals("Cannot parse argument '0' of option ['bs']. The given value 0 should be positive", e.getMessage());
|
|
+ Assert.assertEquals("Cannot parse argument '0' of option bs. The given value 0 should be positive", e.getMessage());
|
|
}
|
|
}
|
|
|
|
@@ -710,7 +710,7 @@
|
|
new CommandLineOptions("-wbs", "0");
|
|
Assert.fail();
|
|
} catch (CommandLineOptionException e) {
|
|
- Assert.assertEquals("Cannot parse argument '0' of option ['wbs']. The given value 0 should be positive", e.getMessage());
|
|
+ Assert.assertEquals("Cannot parse argument '0' of option wbs. The given value 0 should be positive", e.getMessage());
|
|
}
|
|
}
|
|
|