Skip to content

Commit 3f6d415

Browse files
committed
Some test fixing
1 parent 9a427a2 commit 3f6d415

File tree

3 files changed

+7
-3
lines changed

3 files changed

+7
-3
lines changed

tests/server/api/test_movies.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,9 @@ def login(test_user):
5252
@patch("murfey.server.api.auth.check_user", return_value=True)
5353
def test_movie_count(mock_check, test_user):
5454
token = login(test_user)
55-
response = client.get("/num_movies", headers={"Authorization": f"Bearer {token}"})
55+
response = client.get(
56+
"/session_info/num_movies", headers={"Authorization": f"Bearer {token}"}
57+
)
5658
assert mock_check.called_once()
5759
assert response.status_code == 200
5860
assert len(mock_session.method_calls) == 2

tests/server/test_main.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ def login(test_user):
3030
@patch("murfey.server.api.auth.check_user", return_value=True)
3131
def test_read_main(mock_check, test_user):
3232
token = login(test_user)
33-
response = client.get("/", headers={"Authorization": f"Bearer {token}"})
33+
response = client.get("/session_info", headers={"Authorization": f"Bearer {token}"})
3434
assert mock_check.called_once()
3535
assert response.status_code == 200
3636
assert "<title>" in response.text.lower()

tests/util/test_client.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,9 @@ def test_get_visit_list(
109109
visits = _get_visit_list(urlparse(server_url), instrument_name)
110110

111111
# Check that request was sent with the correct URL
112-
expected_url = f"{server_url}/instruments/{instrument_name}/visits_raw"
112+
expected_url = (
113+
f"{server_url}/session_control/instruments/{instrument_name}/visits_raw"
114+
)
113115
mock_request.get.assert_called_once_with(expected_url)
114116

115117
# Check that expected outputs are correct (order-sensitive)

0 commit comments

Comments
 (0)