Skip to content

Commit

Permalink
fix: fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jamescalam committed Jun 20, 2024
1 parent a52b11b commit fca53a6
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions tests/unit/test_layer.py
Original file line number Diff line number Diff line change
Expand Up @@ -244,11 +244,8 @@ def test_remove_route_not_found(self, openai_encoder, routes, index_cls):
)
# Attempt to remove a route that does not exist
non_existent_route = "non-existent-route"
with pytest.raises(ValueError) as excinfo:
route_layer.delete(non_existent_route)
assert (
str(excinfo.value) == f"Route `{non_existent_route}` not found"
), "Attempting to remove a non-existent route should raise a ValueError."
route_layer.delete(non_existent_route)
# we should see warning in logs only (ie no errors)

def test_add_multiple_routes(self, openai_encoder, routes, index_cls):
route_layer = RouteLayer(encoder=openai_encoder, index=index_cls())
Expand Down

0 comments on commit fca53a6

Please sign in to comment.