Skip to content

Commit

Permalink
Updated tests with modifications to Web3 class
Browse files Browse the repository at this point in the history
  • Loading branch information
SethDocherty committed Sep 25, 2024
1 parent 7f596a4 commit 7c6e3e5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion tests/test_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
LOCAL_GATEWAY = "127.0.0.1"
API_PORT = 5001
STAC_ENDPOINT = "fake_endpoint"
GATEWAY_PORT = 8081


@patch('requests.get')
Expand Down Expand Up @@ -50,7 +51,7 @@ def test_to_pd_df(mock_getFromCID, mock_get):

class TestWeb3(SetUp):
def setUp(self):
self.client = Web3(local_gateway=LOCAL_GATEWAY, stac_endpoint=STAC_ENDPOINT)
self.client = Web3(local_gateway=LOCAL_GATEWAY, stac_endpoint=STAC_ENDPOINT, gateway_port=GATEWAY_PORT)

def test_init(self):
self.assertEqual(self.client.local_gateway, LOCAL_GATEWAY)
Expand Down
3 changes: 2 additions & 1 deletion tests/test_client_integration.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,11 @@
LOCAL_GATEWAY = "127.0.0.1"
API_PORT = 5001
STAC_ENDPOINT = "http://ec2-54-172-212-55.compute-1.amazonaws.com/api/v1/pgstac/"
GATEWAY_PORT = 8081

class TestIntegration(SetUp):
def setUp(self):
self.client = Web3(local_gateway=LOCAL_GATEWAY, stac_endpoint=STAC_ENDPOINT)
self.client = Web3(local_gateway=LOCAL_GATEWAY, stac_endpoint=STAC_ENDPOINT, gateway_port=GATEWAY_PORT)
# Colosseum, Rome, Italy
self.bbox = [12.490827, 41.889249, 12.494162, 41.891876]

Expand Down

0 comments on commit 7c6e3e5

Please sign in to comment.