Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
cs2-19wi
project02
Commits
fd7f401f
Commit
fd7f401f
authored
6 years ago
by
Adam Blank
Browse files
Options
Download
Email Patches
Plain Diff
Update ChooserTests.java
parent
43796453
Pipeline
#4066
failed with stage
in 0 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
tests/edu/caltech/cs2/project02/ChooserTests.java
+2
-2
tests/edu/caltech/cs2/project02/ChooserTests.java
with
2 additions
and
2 deletions
+2
-2
tests/edu/caltech/cs2/project02/ChooserTests.java
View file @
fd7f401f
...
...
@@ -77,7 +77,7 @@ public class ChooserTests {
@Test
public
void
testExceptionsViolatedInRandomConstructor
()
{
Constructor
c
=
Reflection
.
getConstructor
(
RandomHangmanChooser
.
class
,
int
.
class
,
int
.
class
);
assertThrows
(
Illegal
State
Exception
.
class
,
()
->
Reflection
.
newInstance
(
c
,
-
1
,
3
));
assertThrows
(
Illegal
Argument
Exception
.
class
,
()
->
Reflection
.
newInstance
(
c
,
-
1
,
3
));
assertThrows
(
IllegalArgumentException
.
class
,
()
->
Reflection
.
newInstance
(
c
,
3
,
-
1
));
assertThrows
(
IllegalStateException
.
class
,
()
->
Reflection
.
newInstance
(
c
,
Integer
.
MAX_VALUE
,
3
));
}
...
...
@@ -193,7 +193,7 @@ public class ChooserTests {
@Test
public
void
testExceptionsViolatedInEvilConstructor
()
{
Constructor
c
=
Reflection
.
getConstructor
(
EvilHangmanChooser
.
class
,
int
.
class
,
int
.
class
);
assertThrows
(
Illegal
State
Exception
.
class
,
()
->
Reflection
.
newInstance
(
c
,
-
1
,
3
));
assertThrows
(
Illegal
Argument
Exception
.
class
,
()
->
Reflection
.
newInstance
(
c
,
-
1
,
3
));
assertThrows
(
IllegalArgumentException
.
class
,
()
->
Reflection
.
newInstance
(
c
,
3
,
-
1
));
assertThrows
(
IllegalStateException
.
class
,
()
->
Reflection
.
newInstance
(
c
,
Integer
.
MAX_VALUE
,
3
));
}
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment
Menu
Projects
Groups
Snippets
Help