From 355bb7ccaf87ddb198fed115fc566707f747c814 Mon Sep 17 00:00:00 2001 From: alex-nork Date: Wed, 30 Aug 2023 17:00:32 +0000 Subject: [PATCH] fix tests --- chirps/asset/tests.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/chirps/asset/tests.py b/chirps/asset/tests.py index 52be06a..f6d8f18 100644 --- a/chirps/asset/tests.py +++ b/chirps/asset/tests.py @@ -138,11 +138,13 @@ def test_api_endpoint_asset_creation(self): form_data = { 'name': 'API Endpoint Asset', + 'description': 'Test API Endpoint Asset', 'url': 'https://api.example.com/endpoint', 'authentication_method': 'Bearer', 'api_key': 'example-api-key', 'headers': '{"Content-Type": "application/json"}', 'body': '{"data": "%query%"}', + 'timeout': '30', } form = APIEndpointAssetForm(data=form_data) self.assertTrue(form.is_valid(), form.errors) @@ -283,7 +285,7 @@ def test_fetch_api_data(self): expected_headers['Authorization'] = f'Bearer {self.api_endpoint_asset.api_key}' expected_body = self.api_endpoint_asset.body.replace('%query%', 'test query') - mock_post.assert_called_once_with(expected_url, headers=expected_headers, json=expected_body, timeout=15) + mock_post.assert_called_once_with(expected_url, headers=expected_headers, json=expected_body, timeout=30) # Assert the search result attributes result = search_results['chat']