Commit 6b6feb97 authored by Andrzej Lisak's avatar Andrzej Lisak

[ABW]: some more tests separated into their own folder

added .orig files to new tests
accepted typical differences in patterns to new tests
some tests renamed to expose main (sort) parameters in their name
parent f5b38d84
{
"code": -32602,
"data": "no account name specified",
"message": "Invalid parameters"
}
......@@ -2,7 +2,7 @@
test_name: bridge_api.list_pop_communities invalid literal # 8080 023
marks:
- patterntest # change to proper error, server error is barely acceptable here
- patterntest
- negative
includes:
......
......@@ -4,7 +4,7 @@
# no nonempty result possible for 5mln set
marks:
- patterntest # change to proper error, server error is barely acceptable here
- patterntest
- negative
includes:
......
......@@ -2,8 +2,9 @@
test_name: bridge_api.list_subscribers account error # not documented
marks:
- patterntest # error should be generated here, but we get empty result (like in original)
- patterntest
- negative
- xfail # error should be generated here, but we get empty result (like in original)
includes:
- !include ../../common.yaml
......@@ -27,3 +28,4 @@
extra_kwargs:
method: "account_error"
directory: "bridge_api_negative/list_subscribers"
error_response: true
{
"code": -32602,
"data": "'author' parameter lacking default value",
"message": "Invalid parameters"
}
{
"code": -32602,
"data": "'author' parameter lacking default value",
"data": "missing a required argument: 'author'",
"message": "Invalid parameters"
}
{
"code": -32602,
"data": "'permlink' parameter lacking default value",
"message": "Invalid parameters"
}
{
"code": -32602,
"data": "'permlink' parameter lacking default value",
"message": "Invalid parameters"
"code": -32602,
"data": "missing a required argument: 'permlink'",
"message": "Invalid parameters"
}
\ No newline at end of file
---
test_name: Hivemind bridge_api.get_account_posts sort blog patterns test
# not documented on https://developers.hive.io/apidefinitions/#apidefinitions-bridge
marks:
- patterntest
includes:
- !include ../../common.yaml
stages:
- name: get_account_posts sort blog
request:
url: "{service.proto:s}://{service.server:s}:{service.port}/"
method: POST
headers:
content-type: application/json
json:
jsonrpc: "2.0"
id: 1
method: "bridge.get_account_posts"
params: {"sort":"blog", "account":"steemit"}
response:
status_code: 200
verify_response_with:
function: validate_response:compare_response_with_pattern
extra_kwargs:
method: "blog_steemit"
directory: "bridge_api_patterns/get_account_posts"
---
test_name: Hivemind bridge_api.get_account_posts sort comments patterns test
marks:
- patterntest # should return posts, now its empty (hive3 hivemind)
includes:
- !include ../../common.yaml
stages:
- name: get_account_posts sort 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: "bridge.get_account_posts"
params: {"sort":"comments", "account":"steemit"}
response:
status_code: 200
verify_response_with:
function: validate_response:compare_response_with_pattern
extra_kwargs:
method: "comments_steemit"
directory: "bridge_api_patterns/get_account_posts"
---
test_name: Hivemind bridge_api.get_account_posts sort feed patterns test
marks:
- patterntest # should return posts, now its empty (hive3 hivemind)
includes:
- !include ../../common.yaml
stages:
- name: get_account_posts sort feed
request:
url: "{service.proto:s}://{service.server:s}:{service.port}/"
method: POST
headers:
content-type: application/json
json:
jsonrpc: "2.0"
id: 1
method: "bridge.get_account_posts"
params: {"sort":"feed", "account":"steemit"}
response:
status_code: 200
verify_response_with:
function: validate_response:compare_response_with_pattern
extra_kwargs:
method: "feed_steemit"
directory: "bridge_api_patterns/get_account_posts"
---
test_name: Hivemind bridge_api.get_account_posts sort payout patterns test
marks:
- patterntest # should return posts, now its empty (hive3 hivemind)
includes:
- !include ../../common.yaml
stages:
- name: get_account_posts sort payout
request:
url: "{service.proto:s}://{service.server:s}:{service.port}/"
method: POST
headers:
content-type: application/json
json:
jsonrpc: "2.0"
id: 1
method: "bridge.get_account_posts"
params: {"sort":"payout", "account":"steemit"}
response:
status_code: 200
verify_response_with:
function: validate_response:compare_response_with_pattern
extra_kwargs:
method: "payout_steemit"
directory: "bridge_api_patterns/get_account_posts"
......@@ -24,5 +24,5 @@
verify_response_with:
function: validate_response:compare_response_with_pattern
extra_kwargs:
method: "gtg_posts"
method: "posts_gtg"
directory: "bridge_api_patterns/get_account_posts"
\ No newline at end of file
---
test_name: Hivemind bridge_api.get_account_posts patterns test
# not documented on https://developers.hive.io/apidefinitions/#apidefinitions-bridge
marks:
- patterntest
includes:
- !include ../../common.yaml
stages:
- name: get_account_posts
request:
url: "{service.proto:s}://{service.server:s}:{service.port}/"
method: POST
headers:
content-type: application/json
json:
jsonrpc: "2.0"
id: 1
method: "bridge.get_account_posts"
params: {"sort":"posts", "account":"steemit"}
response:
status_code: 200
verify_response_with:
function: validate_response:compare_response_with_pattern
extra_kwargs:
method: "posts_steemit"
directory: "bridge_api_patterns/get_account_posts"
......@@ -24,5 +24,5 @@
verify_response_with:
function: validate_response:compare_response_with_pattern
extra_kwargs:
method: "gtg"
method: "replies_gtg"
directory: "bridge_api_patterns/get_account_posts"
\ No newline at end of file
......@@ -24,5 +24,5 @@
verify_response_with:
function: validate_response:compare_response_with_pattern
extra_kwargs:
method: "rollinshive"
method: "replies_rollinshive"
directory: "bridge_api_patterns/get_account_posts"
\ No newline at end of file
---
test_name: Hivemind bridge_api.get_account_posts sort replies patterns test
# not documented on https://developers.hive.io/apidefinitions/#apidefinitions-bridge
marks:
- patterntest
includes:
- !include ../../common.yaml
stages:
- name: get_account_posts sort replies
request:
url: "{service.proto:s}://{service.server:s}:{service.port}/"
method: POST
headers:
content-type: application/json
json:
jsonrpc: "2.0"
id: 1
method: "bridge.get_account_posts"
params: {"sort":"replies", "account":"steemit"}
response:
status_code: 200
verify_response_with:
function: validate_response:compare_response_with_pattern
extra_kwargs:
method: "replies_steemit"
directory: "bridge_api_patterns/get_account_posts"
......@@ -2,7 +2,7 @@
test_name: Hivemind condenser_api.get_active_votes patterns test 3 args 33091
marks:
- patterntest # change to proper error, server error is barely acceptable here
- patterntest
- negative
includes:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment