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

Function test_promising

tests/search/test_SearchSpace.py:111–123  ·  view source on GitHub ↗

Tests marking clients as promising.

(ok_small)

Source from the content-addressed store, hash-verified

109
110
111def test_promising(ok_small):
112 """
113 Tests marking clients as promising.
114 """
115 search_space = SearchSpace(ok_small, compute_neighbours(ok_small))
116
117 for client in range(ok_small.num_depots, ok_small.num_locations):
118 # The client does not start off promising.
119 assert_(not search_space.is_promising(client))
120
121 # But it is after being marked promising.
122 search_space.mark_promising(client)
123 assert_(search_space.is_promising(client))
124
125
126def test_all_promising(ok_small):

Callers

nothing calls this directly

Calls 2

compute_neighboursFunction · 0.90
SearchSpaceClass · 0.85

Tested by

no test coverage detected