MCPcopy Create free account
hub / github.com/PyVRP/PyVRP / test_eq_checks_names

Function test_eq_checks_names

tests/test_ProblemData.py:1047–1056  ·  view source on GitHub ↗

Tests that the equality operators on named objects also considers the name when determining equality.

()

Source from the content-addressed store, hash-verified

1045
1046
1047def test_eq_checks_names():
1048 """
1049 Tests that the equality operators on named objects also considers the name
1050 when determining equality.
1051 """
1052 x, y = 0, 0
1053 assert_(Client(x, y, name="1") != Client(x, y, name="2"))
1054 assert_(Depot(x, y, name="1") != Depot(x, y, name="2"))
1055 assert_(VehicleType(name="1") != VehicleType(name="2"))
1056 assert_(ClientGroup(name="1") != ClientGroup(name="2"))
1057
1058
1059@pytest.mark.parametrize("cls", (Client, Depot))

Callers

nothing calls this directly

Calls 4

ClientClass · 0.90
DepotClass · 0.90
VehicleTypeClass · 0.90
ClientGroupClass · 0.90

Tested by

no test coverage detected