Skip to content

Commit

Permalink
Add test for LinkType.setOutputType
Browse files Browse the repository at this point in the history
  • Loading branch information
lacinoire committed Jun 20, 2022
1 parent f4e9cde commit 9f0e4fa
Showing 1 changed file with 12 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -64,4 +64,16 @@ public void testIsPluginTrue() {
type.setOutputType(pluginType);
assertTrue(type.isPluginModule());
}

public void testSetOutputType() throws Exception {
try {
final LinkType type = new LinkType();
final OutputTypeEnum pluginType = new OutputTypeEnum();
pluginType.setValue("executable");
type.setOutputType(null);
TestCase.fail("testSetOutputType should have thrown IllegalArgumentException");
} catch (IllegalArgumentException expected) {
TestCase.assertEquals("outputType", expected.getMessage());
}
}
}

0 comments on commit 9f0e4fa

Please sign in to comment.