Checkpoint
This commit is contained in:
@ -1,20 +1,22 @@
|
||||
package com.plannaplan;
|
||||
|
||||
import static org.junit.Assert.assertTrue;
|
||||
import java.util.List;
|
||||
|
||||
import org.junit.Assert;
|
||||
import org.junit.Test;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
|
||||
/**
|
||||
* Unit test for simple App.
|
||||
*/
|
||||
public class AppTest
|
||||
{
|
||||
/**
|
||||
* Rigorous Test :-)
|
||||
*/
|
||||
public class AppTest {
|
||||
@Autowired
|
||||
private BookService bookService;
|
||||
|
||||
@Test
|
||||
public void shouldAnswerWithTrue()
|
||||
{
|
||||
assertTrue( true );
|
||||
public void whenApplicationStarts_thenHibernateCreatesInitialRecords() {
|
||||
List<Book> books = bookService.list();
|
||||
|
||||
Assert.assertEquals(books.size(), 1);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user