package com.twu.biblioteca.entity;

import org.junit.Before;
import org.junit.Test;

import static org.junit.Assert.assertEquals;

public class BookTest {
    private Book book;

    @Before
    public void initBook() {
        book = new Book();
    }

    @Test
    public void canSetBookName() {
        String name = "Refactoring: Improving the Design of Existing Code";
        book.setName(name);
        assertEquals(name, book.getName());
    }

}

@@ -447,10 +447,185 @@
 %0A    %7D%0A%0A
+    @Test%0A    public void canSetBookAuthor() %7B%0A        String author = %22Martin Fowler%22;%0A        book.setAuthor(author);%0A        assertEquals(author, book.getAuthor());%0A    %7D%0A%0A
 %7D%0A

test setAuthor function