Skip to content
Snippets Groups Projects
Commit b4f55175 authored by Sara Savanovic Djordjevic's avatar Sara Savanovic Djordjevic
Browse files

fix: schedler

parents b164047d e33fe81a
No related branches found
No related tags found
1 merge request!21Clhp map
Showing
with 11929 additions and 3737 deletions
No preview for this file type
No preview for this file type
This diff is collapsed.
No preview for this file type
No preview for this file type
No preview for this file type
No preview for this file type
No preview for this file type
No preview for this file type
No preview for this file type
......@@ -27,9 +27,8 @@ def test_add_new_lidar_measurement_valid_lake() -> None:
os.makedirs(dir_path)
# expectations
actual, u = add_new_lidar_measurement(lake_name, lat, lon)
actual, _ = add_new_lidar_measurement(lake_name, lat, lon)
expected = 200
print("sub", u)
# remove temporary files and directories
if os.path.exists(file_path):
os.remove(file_path)
......
No preview for this file type
No preview for this file type
......@@ -32,7 +32,7 @@ def test_new_input_invalid_lake() -> None:
def test_new_input_unvalid_cursor() -> None:
sensor_id = 1
test_lake_name = "Mjøsa"
test_lake_name = "skumsjøen"
# create a mock cursor
mock_cursor = MagicMock()
mock_cursor.execute.side_effect = \
......@@ -63,21 +63,3 @@ def test_new_input_unvalid_cursor() -> None:
status_code, _ = input_new_Lidar_data(mock_cursor, sensor_id, test_lake_name)
assert status_code == 500
'''
def test_new_input_valid_cursor() -> None:
sensor_id = 1
test_lake_name = "Mjøsa"
# create a mock cursor
mock_cursor = MagicMock()
mock_cursor.execute.side_effect = [
[('Mjøsa'),],
None,
None,
None
]
status_code, _ = input_new_Lidar_data(mock_cursor, sensor_id, test_lake_name)
assert status_code == 200
'''
\ No newline at end of file
No preview for this file type
No preview for this file type
[
"Mjøsa",
"Skumsjøen",
"test_lake"
"Skumsjøen"
]
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment