From 20fdb1ae114a6b43313c1a3da4e7e54b8c808edb Mon Sep 17 00:00:00 2001 From: Thomas Lindner Date: Sat, 18 Mar 2023 16:40:14 +0100 Subject: [PATCH] [tests] Prevent pytest from hanging --- backend/tests/tests_core/test_api_test.py | 37 ----------------------- 1 file changed, 37 deletions(-) delete mode 100644 backend/tests/tests_core/test_api_test.py diff --git a/backend/tests/tests_core/test_api_test.py b/backend/tests/tests_core/test_api_test.py deleted file mode 100644 index 7243d90..0000000 --- a/backend/tests/tests_core/test_api_test.py +++ /dev/null @@ -1,37 +0,0 @@ -# Copyright (C) 2020 by Christian -# Copyright (C) 2020 by Thomas Lindner -# Copyright (C) 2020 by Martin Rey -# -# SPDX-License-Identifier: 0BSD - -from fastapi import status - - -def test_test_read_all_unauthorized(client, hood_id): - response = client.get('/api/hoods/{0}/test/'.format(hood_id)) - assert response.status_code == status.HTTP_401_UNAUTHORIZED - - -def test_test_create_unauthorized(client, hood_id): - response = client.post('/api/hoods/{0}/test/'.format(hood_id)) - assert response.status_code == status.HTTP_401_UNAUTHORIZED - - -def test_test_read_unauthorized(client, hood_id, test_id): - response = client.get('/api/hoods/{0}/test/{1}'.format(hood_id, test_id)) - assert response.status_code == status.HTTP_401_UNAUTHORIZED - - -def test_test_delete_unauthorized(client, hood_id, test_id): - response = client.delete('/api/hoods/{0}/test/{1}'.format(hood_id, test_id)) - assert response.status_code == status.HTTP_401_UNAUTHORIZED - - -def test_test_message_read_all_unauthorized(client, hood_id, test_id): - response = client.get('/api/hoods/{0}/test/{1}/messages/'.format(hood_id, test_id)) - assert response.status_code == status.HTTP_401_UNAUTHORIZED - - -def test_test_message_create_unauthorized(client, hood_id, test_id): - response = client.post('/api/hoods/{0}/test/{1}/messages/'.format(hood_id, test_id)) - assert response.status_code == status.HTTP_401_UNAUTHORIZED