Cleaned up some code
This commit is contained in:
parent
e51d275b76
commit
49e145d098
|
@ -29,8 +29,8 @@ public interface LispInterpreterBuilder {
|
|||
|
||||
void setCriticalOutputDecorator(Function<String, String> criticalOutputDecorator);
|
||||
|
||||
default void reset() {}
|
||||
|
||||
LispInterpreter build();
|
||||
|
||||
default void reset() {}
|
||||
|
||||
}
|
||||
|
|
|
@ -68,11 +68,21 @@ public class LispInterpreterBuilderTester {
|
|||
builder.build();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void interpreterAlreadyBuiltException_HasMessage() {
|
||||
InterpreterAlreadyBuiltException e = new InterpreterAlreadyBuiltException();
|
||||
InterpreterAlreadyBuiltException e = new InterpreterAlreadyBuiltException();
|
||||
|
||||
assertNotNull(e.getMessage());
|
||||
assertTrue(e.getMessage().length() > 0);
|
||||
assertNotNull(e.getMessage());
|
||||
assertTrue(e.getMessage().length() > 0);
|
||||
}
|
||||
|
||||
@Test(expected = InterpreterAlreadyBuiltException.class)
|
||||
public void resetNormallyDoesNothing() {
|
||||
builder = new LispInterpreterBuilderImpl();
|
||||
|
||||
builder.build();
|
||||
builder.reset();
|
||||
builder.build();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -1,10 +1,7 @@
|
|||
package main;
|
||||
|
||||
import static org.junit.Assert.*;
|
||||
|
||||
import org.junit.*;
|
||||
|
||||
|
||||
public class MainTester {
|
||||
|
||||
@Before
|
||||
|
@ -13,9 +10,4 @@ public class MainTester {
|
|||
@After
|
||||
public void tearDown() throws Exception {}
|
||||
|
||||
@Test
|
||||
public void test() {
|
||||
fail("Not yet implemented");
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue