updated gitignore, Merge branch 'updateCientServer' of gitlab.ewi.tudelft.nl:cse1105/2018-2019/oopp-group-43/template
This commit is contained in:
6
Server/src/test/java/ApplicationTest.java
Normal file
6
Server/src/test/java/ApplicationTest.java
Normal file
@@ -0,0 +1,6 @@
|
||||
import org.junit.Test;
|
||||
public class ApplicationTest {
|
||||
@Test
|
||||
public void main() {
|
||||
}
|
||||
}
|
||||
14
Server/src/test/java/GreetingControllerTest.java
Normal file
14
Server/src/test/java/GreetingControllerTest.java
Normal file
@@ -0,0 +1,14 @@
|
||||
import hello.Greeting;
|
||||
import hello.GreetingController;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
import static org.assertj.core.api.AssertionsForClassTypes.assertThat;
|
||||
|
||||
public class GreetingControllerTest {
|
||||
@Test
|
||||
void nullTest() {
|
||||
GreetingController controller = new GreetingController();
|
||||
assertThat(controller).isNotNull();
|
||||
}
|
||||
}
|
||||
|
||||
15
Server/src/test/java/GreetingTest.java
Normal file
15
Server/src/test/java/GreetingTest.java
Normal file
@@ -0,0 +1,15 @@
|
||||
import hello.Greeting;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
import static org.assertj.core.api.AssertionsForClassTypes.assertThat;
|
||||
|
||||
public class GreetingTest {
|
||||
@Test
|
||||
void testGets() {
|
||||
Greeting greeting = new Greeting(1, "hello");
|
||||
long id = greeting.getId();
|
||||
String content = greeting.getContent();
|
||||
assertThat(id).isEqualTo(1);
|
||||
assertThat(content).isEqualTo(content);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user