def test_existing_id(self): self.assertEqual(create_uniqe_id("Foo", ["foo"]), "foo-1") self.assertEqual(create_uniqe_id("Foo", ["foo", "foo-1"]), "foo-2")
def test_spaces(self): self.assertEqual(create_uniqe_id("Foo bar", []), "foo-bar")
def test_first_id(self): self.assertEqual(create_uniqe_id("Foo", []), "foo")