def test_size(): graph = Graph() a = graph.add_node('a') b = graph.add_node('b') expected = 2 actual = graph.size() assert actual == expected
def test_size_empty(): graph = Graph() expected = 0 actual = graph.size() assert actual == expected
def test_size_one(): graph = Graph() graph.add_node("spam") expected = 1 actual = graph.size() assert actual == expected
def test_size_two(): graph = Graph() graph.add_node("spam") graph.add_node("bacon") expected = 2 actual = graph.size() assert actual == expected