11from unittest .mock import ANY
2-
2+ import pytest
33from faker import Faker
44from flask import json
55from flask .testing import FlaskClient
1818
1919fake_activity = ({"id" : fake .random_int (1 , 9999 )}).update (valid_activity_data )
2020
21+ def test_get_all_activities_return_list_activities_when_send_get_request (
22+ client : FlaskClient , valid_header : dict
23+ ):
24+ response = client .get (
25+ "/activities" , headers = valid_header , follow_redirects = True
26+ )
27+
28+ assert HTTPStatus .OK == response .status_code
2129
2230def test_create_activity_should_succeed_with_valid_request (
2331 client : FlaskClient , mocker : MockFixture , valid_header : dict
@@ -55,7 +63,7 @@ def test_create_activity_should_reject_bad_request(
5563 assert HTTPStatus .BAD_REQUEST == response .status_code
5664 repository_create_mock .assert_not_called ()
5765
58-
66+ @ pytest . mark . skip ( reason = "There is currently no way to test this. Getting the value of the azure blob storage" )
5967def test_list_all_active (
6068 client : FlaskClient , mocker : MockFixture , valid_header : dict
6169):
@@ -81,7 +89,7 @@ def test_list_all_active(
8189 max_count = ANY ,
8290 )
8391
84-
92+ @ pytest . mark . skip ( reason = "There is currently no way to test this. Getting the value of the azure blob storage" )
8593def test_list_all_active_activities (
8694 client : FlaskClient , mocker : MockFixture , valid_header : dict
8795):
0 commit comments