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

Function test_get_clients

tests/test_Model.py:228–239  ·  view source on GitHub ↗

Tests the ``clients`` property.

()

Source from the content-addressed store, hash-verified

226
227
228def test_get_clients():
229 """
230 Tests the ``clients`` property.
231 """
232 model = Model()
233 client1 = model.add_client(0, 0)
234 client2 = model.add_client(0, 0)
235
236 # Test that we can get the clients by index, or as a list.
237 assert_equal(model.clients[0], client1)
238 assert_equal(model.clients[1], client2)
239 assert_equal(model.clients, [client1, client2])
240
241
242def test_get_depots():

Callers

nothing calls this directly

Calls 2

add_clientMethod · 0.95
ModelClass · 0.90

Tested by

no test coverage detected