Skip to content
This repository has been archived by the owner on Oct 18, 2023. It is now read-only.

Commit

Permalink
creating a new testing set of resources
Browse files Browse the repository at this point in the history
  • Loading branch information
vggonzal authored and vggonzal committed Aug 16, 2023
1 parent c07689f commit 33cb4ab
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 6 deletions.
4 changes: 2 additions & 2 deletions hydrocronapi/controllers/db/db.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ def get_reach_series(start_time: datetime, end_time: datetime) -> Generator:
response = dynamodb.get_item(
TableName=table_name,
Key={
'feature_id': {'S': '71224100223'}
'reach_id': {'S': '71224100223'}
}
)
print("get_item")
Expand Down Expand Up @@ -45,7 +45,7 @@ def get_reach_series_by_feature_id(feature_id: str, start_time: datetime, end_ti
response = dynamodb.get_item(
TableName=table_name,
Key={
'feature_id': {'S': feature_id}
'reach_id': {'S': feature_id}
}
)
print("get_item")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ paths:
{
"body": {
"feature":"$input.params('feature')",
"feature_id":"$input.params('feature_id')",
"feature_id":"$input.params('reach_id')",
"start_time":"$input.params('start_time')",
"end_time":"$input.params('end_time')",
"output": "$input.params('output')",
Expand Down
2 changes: 0 additions & 2 deletions tests/example_load_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@ def upload():
for index, row in shp_file.iterrows():
object = {}
for k, v in row.items():
if (k == 'reach_id'):
k = 'feature_id'
object[k] = {'S' : str(v)}
response = dynamodb.put_item(
TableName='hydrocron_swot_reaches_test',
Expand Down
2 changes: 1 addition & 1 deletion tests/test_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ def test_gettimeseries_get(self):
Get Timeseries for a particular Reach, Node, or LakeID
"""
query_string = [('feature', 'Reach'),
('feature_id', '73254700251'),
('reach_id', '73254700251'),
('format', 'csv'),
('start_time', '2022-08-04T00:00:00+00:00'),
('end_time', '2022-08-23T00:00:00+00:00')]
Expand Down

0 comments on commit 33cb4ab

Please sign in to comment.