class TestPagingDestinationBuilder(unittest.TestCase): def setUp(self): self.builder = PagingDestinationBuilder() def test_given_destination_type_paging_then_returns_paging_destination(self): dest = {"type": "paging", "paging_id": 1} expected = PagingDestination(paging_id=1) result = self.builder.build(dest) assert_that(result, equal_to(expected))