Skip to content
Snippets Groups Projects
Commit bbfc76aa authored by Paulina Czempiel's avatar Paulina Czempiel
Browse files

condenser_api tests get_discussions_by_comments moved to folder

parent 603a9aa3
No related branches found
No related tags found
1 merge request!81condenser_api tests get_discussions_by_comments moved to folder
{
"code": -32602,
"data": "get_discussions_by_comments() got an unexpected keyword argument 'author'",
"message": "Invalid parameters"
}
{
"code": -32602,
"data": "get_discussions_by_comments() got an unexpected keyword argument 'author'",
"message": "Invalid parameters"
}
---
test_name: Hivemind condenser_api.get_discussions_by_comments unexpected keyword patterns test
marks:
- patterntest
- negative
# while this would be acceptable we should change it to invalid parameters over server error (code suggests we wanted to completely silence that, but rest passes is as generic error, old code was the same so...)
includes:
- !include ../../common.yaml
stages:
- name: get_replies_by_last_update unexpected keyword
request:
url: "{service.proto:s}://{service.server:s}:{service.port}/"
method: POST
headers:
content-type: application/json
json:
jsonrpc: "2.0"
id: 1
method: "condenser_api.get_discussions_by_comments"
params: [{"author": "steemit"}]
response:
status_code: 200
verify_response_with:
function: validate_response:compare_response_with_pattern
extra_kwargs:
method: "unexpected_keyword"
directory: "condenser_api_negative/get_discussions_by_comments"
error_response: true
\ No newline at end of file
[
{
"active_votes": [
{
"percent": "-100",
"reputation": 0,
"rshares": "-375241",
"voter": "dantheman"
},
{
"percent": "10000",
"reputation": 0,
"rshares": "5100",
"voter": "steemit46"
},
{
"percent": "10000",
"reputation": 0,
"rshares": "81125",
"voter": "roadscape"
},
{
"percent": "10000",
"reputation": 0,
"rshares": "425903066",
"voter": "gekko"
},
{
"percent": "10000",
"reputation": 0,
"rshares": "431616594",
"voter": "acidyo"
},
{
"percent": "10000",
"reputation": 0,
"rshares": "742566481",
"voter": "patrick-g"
},
{
"percent": "10000",
"reputation": 0,
"rshares": "58854897335",
"voter": "business"
},
{
"percent": "10000",
"reputation": 0,
"rshares": "108855472",
"voter": "kingtylervvs"
},
{
"percent": "10000",
"reputation": 0,
"rshares": "244129227",
"voter": "kewpiedoll"
},
{
"percent": "10000",
"reputation": 0,
"rshares": "1615731741",
"voter": "naturalista"
}
],
"author": "admin",
"author_reputation": 0,
"beneficiaries": [],
"body": "First Reply! Let's get this **party** started",
"body_length": 45,
"cashout_time": "1969-12-31T23:59:59",
"category": "meta",
"children": 2,
"created": "2016-03-30T19:52:30",
"curator_payout_value": "0.000 HBD",
"depth": 1,
"json_metadata": "{}",
"last_payout": "2016-08-24T19:59:42",
"last_update": "2016-03-30T19:52:30",
"max_accepted_payout": "1000000.000 HBD",
"net_rshares": 62423410900,
"parent_author": "steemit",
"parent_permlink": "firstpost",
"pending_payout_value": "0.000 HBD",
"percent_steem_dollars": 10000,
"permlink": "firstpost",
"post_id": 2,
"promoted": "0.000 HBD",
"replies": [],
"root_title": "Welcome to Steem!",
"title": "",
"total_payout_value": "0.000 HBD",
"url": "/meta/@steemit/firstpost#@admin/firstpost"
}
]
[
{
"active_votes": [
{
"percent": "-100",
"reputation": 0,
"rshares": "-375241",
"voter": "dantheman"
},
{
"percent": "10000",
"reputation": 0,
"rshares": "5100",
"voter": "steemit46"
},
{
"percent": "10000",
"reputation": 0,
"rshares": "81125",
"voter": "roadscape"
},
{
"percent": "10000",
"reputation": 0,
"rshares": "425903066",
"voter": "gekko"
},
{
"percent": "10000",
"reputation": 0,
"rshares": "431616594",
"voter": "acidyo"
},
{
"percent": "10000",
"reputation": 0,
"rshares": "742566481",
"voter": "patrick-g"
},
{
"percent": "10000",
"reputation": 0,
"rshares": "58854897335",
"voter": "business"
},
{
"percent": "10000",
"reputation": 0,
"rshares": "108855472",
"voter": "kingtylervvs"
},
{
"percent": "10000",
"reputation": 0,
"rshares": "244129227",
"voter": "kewpiedoll"
},
{
"percent": "10000",
"reputation": 0,
"rshares": "1615731741",
"voter": "naturalista"
}
],
"author": "admin",
"author_reputation": 0,
"beneficiaries": [],
"body": "First Reply! Let's get this **party** started",
"body_length": 45,
"cashout_time": "1969-12-31T23:59:59",
"category": "meta",
"children": 2,
"created": "2016-03-30T19:52:30",
"curator_payout_value": "0.000 HBD",
"depth": 1,
"json_metadata": "",
"last_payout": "2016-08-24T19:59:42",
"last_update": "2016-03-30T19:52:30",
"max_accepted_payout": "1000000.000 HBD",
"net_rshares": 62423410900,
"parent_author": "steemit",
"parent_permlink": "firstpost",
"pending_payout_value": "0.000 HBD",
"percent_hbd": 10000,
"permlink": "firstpost",
"post_id": 2,
"promoted": "0.000 HBD",
"replies": [],
"root_title": "Welcome to Steem!",
"title": "",
"total_payout_value": "0.000 HBD",
"url": "/meta/@steemit/firstpost#@admin/firstpost"
}
]
\ No newline at end of file
---
test_name: Hivemind condenser_api.get_discussions_by_comments patterns test
marks:
- patterntest
includes:
- !include ../../common.yaml
stages:
- name: get_discussions_by_comments
request:
url: "{service.proto:s}://{service.server:s}:{service.port}/"
method: POST
headers:
content-type: application/json
json:
jsonrpc: "2.0"
id: 1
method: "condenser_api.get_discussions_by_comments"
params: {"start_author":"admin","start_permlink":"firstpost","limit":1}
response:
status_code: 200
verify_response_with:
function: validate_response:compare_response_with_pattern
extra_kwargs:
method: "admin"
directory: "condenser_api_patterns/get_discussions_by_comments"
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment