Skip to content
Permalink
Browse files
updated unit tests (#76)
  • Loading branch information
waso committed Oct 23, 2021
1 parent 897593c commit 234062c7d9e7917e2ff01ac3b534e053759c5c6c
Showing 2 changed files with 21 additions and 1 deletion.
@@ -62,7 +62,7 @@
<action type="add" dev="ggregory" due-to="Alex Nordlund" issue="CLI-282">
TypeHandler should throw ParseException for an unsupported class.
</action>
<action type="add" dev="ggregory" due-to="waso, Gary Gregory">
<action type="add" dev="ggregory" due-to="Waldemar Sojka, Gary Gregory">
Added setter for Builder.option #33.
</action>
<!-- UPDATE -->
@@ -81,6 +81,26 @@ public void testBuilderInsufficientParams2() {
Option.builder(null).desc("desc").build();
}

@Test(expected = IllegalArgumentException.class)
public void testBuilderInvalidOptionName1() {
Option.builder().option("invalid?");
}

@Test(expected = IllegalArgumentException.class)
public void testBuilderInvalidOptionName2() {
Option.builder().option("invalid@");
}

@Test(expected = IllegalArgumentException.class)
public void testBuilderInvalidOptionName3() {
Option.builder("invalid?");
}

@Test(expected = IllegalArgumentException.class)
public void testBuilderInvalidOptionName4() {
Option.builder("invalid@");
}

@Test
public void testBuilderMethods() {
final char defaultSeparator = (char) 0;

0 comments on commit 234062c

Please sign in to comment.