List removed posts
Last evaluated key for pagination
This commit is contained in:
parent
e1a8e008e1
commit
2b608be054
9 changed files with 35 additions and 282 deletions
|
|
@ -1,4 +1,5 @@
|
|||
import unittest
|
||||
import unittest, simplejson as json
|
||||
from unittest.mock import patch
|
||||
from trustcafeapiwrapper.apiclient import APIClient
|
||||
class TestAPIClient(unittest.TestCase):
|
||||
def setUp(self):
|
||||
|
|
@ -45,3 +46,11 @@ class TestAPIClient(unittest.TestCase):
|
|||
|
||||
result = self.api_client.run_job(mock_job, "value1")
|
||||
self.assertEqual(result, "Job executed with value1")
|
||||
|
||||
@patch('trustcafeapiwrapper.apiclient.requests.request')
|
||||
def test_make_request(self, mock_request):
|
||||
# This is a placeholder test. In a real test, you'd mock the HTTP request and response.
|
||||
|
||||
response = self.api_client.make_request("GET", "content", "https://api.example.com/test")
|
||||
#
|
||||
mock_request.assert_called_once()
|
||||
Loading…
Add table
Add a link
Reference in a new issue