Exemplo n.º 1
0
    def test_get_num_available_books_with_zero_quantity(self):
        book = BookFactory(quantity=0)

        num_available = book.get_num_available_book()

        self.assertEqual(0, num_available)
Exemplo n.º 2
0
    def test_get_num_available_books_with_quantity_greater_than_zero(self):
        book = BookFactory(quantity=3)

        num_available = book.get_num_available_book()

        self.assertEqual(3, num_available)
Exemplo n.º 3
0
    def test_get_book_deadline_method_empty_book(self):
        book = BookFactory()

        deadline = book.get_book_deadline()

        self.assertEqual({}, deadline)