- @Test
- @DisplayName("A new sum can be started, if it does not exist")
- public void testStartSumPossibleIfNotExists()
- {
- AdderBusinessLogic adder = new AdderBusinessLogic();
- assertThatNoException().isThrownBy(() -> adder.startSum("foo"));
- }
-
- @Test
- @DisplayName("Starting an already existing sum again, causes an IllegalStateException")
- public void testStartSumCausesExceptionIfExists()
- {
- AdderBusinessLogic adder = new AdderBusinessLogic();
- adder.startSum("foo");
- assertThatIllegalStateException().isThrownBy(() -> adder.startSum("foo"));
- }
-