diff options
author | Marc R. Hoffmann <hoffmann@mountainminds.com> | 2016-02-17 15:28:28 +0100 |
---|---|---|
committer | Evgeny Mandrikov <mandrikov@gmail.com> | 2016-02-17 15:28:28 +0100 |
commit | e83313313ce1020fe203856446ca9bb2ce06f433 (patch) | |
tree | 26198944ddb3d23f75a02fe223d71aa4920a48fd /org.jacoco.core.test | |
parent | 8c697001026906a0804f31220b62c2ee7140292d (diff) | |
download | jacoco-e83313313ce1020fe203856446ca9bb2ce06f433.tar.gz |
GitHub #358: Correct error handling for invalid agent arguments
In case of invalid agent arguments (e.g. usage of upper case letters)
such arguments must be reported properly.
Diffstat (limited to 'org.jacoco.core.test')
-rw-r--r-- | org.jacoco.core.test/src/org/jacoco/core/runtime/AgentOptionsTest.java | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/org.jacoco.core.test/src/org/jacoco/core/runtime/AgentOptionsTest.java b/org.jacoco.core.test/src/org/jacoco/core/runtime/AgentOptionsTest.java index 886b2f99..b2d189e4 100644 --- a/org.jacoco.core.test/src/org/jacoco/core/runtime/AgentOptionsTest.java +++ b/org.jacoco.core.test/src/org/jacoco/core/runtime/AgentOptionsTest.java @@ -362,7 +362,7 @@ public class AgentOptionsTest { @Test(expected = IllegalArgumentException.class) public void testInvalidOptionKey() { - new AgentOptions("destfile=test.exec,something=true"); + new AgentOptions("destfile=test.exec,Some-thing_1=true"); } @Test(expected = IllegalArgumentException.class) @@ -468,11 +468,10 @@ public class AgentOptionsTest { } @Test - // issue #358 - public void testDestFileWithComma() { + public void testOptionValueWithSpecialCharacters() { AgentOptions options = new AgentOptions( - "destfile=build/jacoco/foo, bar.exec"); - assertEquals("build/jacoco/foo, bar.exec", options.getDestfile()); + "destfile=build/jacoco/foo, bar-1_0.exec"); + assertEquals("build/jacoco/foo, bar-1_0.exec", options.getDestfile()); } } |