DATACMNS-1755 - Use specialized assertThat*Exception.
When possible replace `assertThatExceptionOfType` calls with the equivalent specialized variant. Original pull request: #448.
This commit is contained in:
committed by
Mark Paluch
parent
86bda64daa
commit
5734cfe878
@@ -78,7 +78,7 @@ class LazyUnitTests {
|
||||
@Test
|
||||
void rejectsNullValueLookup() {
|
||||
|
||||
assertThatExceptionOfType(IllegalStateException.class) //
|
||||
assertThatIllegalStateException() //
|
||||
.isThrownBy(() -> Lazy.of(() -> null).get());
|
||||
}
|
||||
|
||||
|
||||
@@ -37,7 +37,7 @@ class MethodInvocationRecorderUnitTests {
|
||||
@Test // DATACMNS-1449
|
||||
void rejectsFinalTypes() {
|
||||
|
||||
assertThatExceptionOfType(IllegalArgumentException.class) //
|
||||
assertThatIllegalArgumentException() //
|
||||
.isThrownBy(() -> MethodInvocationRecorder.forProxyOf(FinalType.class));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user