NodeExceptionTest: use lombok's val
Signed-off-by: Paul Campbell <pcampbell@kemitix.net>
This commit is contained in:
parent
58363e474d
commit
24ad03ccab
1 changed files with 3 additions and 9 deletions
|
@ -1,7 +1,6 @@
|
|||
package net.kemitix.node;
|
||||
|
||||
import net.kemitix.node.NodeException;
|
||||
|
||||
import lombok.val;
|
||||
import org.junit.Test;
|
||||
|
||||
import static org.hamcrest.CoreMatchers.is;
|
||||
|
@ -14,20 +13,15 @@ import static org.junit.Assert.assertThat;
|
|||
*/
|
||||
public class NodeExceptionTest {
|
||||
|
||||
/**
|
||||
* Class under test.
|
||||
*/
|
||||
private NodeException nodeException;
|
||||
|
||||
/**
|
||||
* Test that message provided to constructor is returned.
|
||||
*/
|
||||
@Test
|
||||
public void shouldReturnConstructorMessage() {
|
||||
//given
|
||||
final String message = "this is the message";
|
||||
val message = "this is the message";
|
||||
//when
|
||||
nodeException = new NodeException(message);
|
||||
val nodeException = new NodeException(message);
|
||||
//then
|
||||
assertThat(nodeException.getMessage(), is(message));
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue