Skip to content
Snippets Groups Projects
Commit 0856ef01 authored by Pawel Maniora's avatar Pawel Maniora
Browse files

communities tests

parent 53ce2ce8
No related branches found
No related tags found
No related merge requests found
[
{
"about": "Banana-nothing.",
"admins": [
"test-safari"
],
"avatar_url": "",
"context": {
"role": "guest",
"subscribed": true,
"title": ""
},
"created_at": "2016-09-15 19:47:15",
"id": 92476,
"is_nsfw": true,
"lang": "en",
"name": "hive-171487",
"num_authors": 0,
"num_pending": 0,
"subscribers": 4,
"sum_pending": 0,
"title": "Banana",
"type_id": 1
}
]
---
test_name: Hivemind bridge_api.list_communities patterns test hive-171487
# not documented on https://developers.hive.io/apidefinitions/#apidefinitions-bridge
marks:
- patterntest
# Communities not implemented under 5 mln blocks, but some were created by mock mechanism, therefore they are in result.
includes:
- !include ../../common.yaml
stages:
- name: list_communities hive-171487
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.list_communities"
params: {"last":"hive-171488", "limit":1, "observer":"gtg"}
response:
status_code: 200
verify_response_with:
function: validate_response:compare_response_with_pattern
extra_kwargs:
method: "hive-171487_observer_gtg"
directory: "bridge_api_patterns/list_communities"
[
{
"about": "Banana-nothing.",
"admins": [
"test-safari"
],
"avatar_url": "",
"context": {},
"created_at": "2016-09-15 19:47:15",
"id": 92476,
"is_nsfw": true,
"lang": "en",
"name": "hive-171487",
"num_authors": 0,
"num_pending": 0,
"subscribers": 4,
"sum_pending": 0,
"title": "Banana",
"type_id": 1
}
]
---
test_name: Hivemind bridge_api.list_communities patterns test query banana
# not documented on https://developers.hive.io/apidefinitions/#apidefinitions-bridge
marks:
- patterntest
# Communities not implemented under 5 mln blocks, but some were created by mock mechanism, therefore they are in result.
includes:
- !include ../../common.yaml
stages:
- name: list_communities query banana
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.list_communities"
params: {"limit":100, "query":"banana"}
response:
status_code: 200
verify_response_with:
function: validate_response:compare_response_with_pattern
extra_kwargs:
method: "query_banana"
directory: "bridge_api_patterns/list_communities"
[
{
"about": "A place for major news from around the world.",
"admins": [
"blocktrades",
"test-safari"
],
"avatar_url": "",
"context": {},
"created_at": "2016-09-15 19:47:15",
"id": 92478,
"is_nsfw": true,
"lang": "en",
"name": "hive-135485",
"num_authors": 2,
"num_pending": 5,
"subscribers": 4,
"sum_pending": 0,
"title": "World News",
"type_id": 1
}
]
---
test_name: Hivemind bridge_api.list_communities patterns test query major
# not documented on https://developers.hive.io/apidefinitions/#apidefinitions-bridge
marks:
- patterntest
# Communities not implemented under 5 mln blocks, but some were created by mock mechanism, therefore they are in result.
includes:
- !include ../../common.yaml
stages:
- name: list_communities query_major
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.list_communities"
params: {"limit":100, "query":"major"}
response:
status_code: 200
verify_response_with:
function: validate_response:compare_response_with_pattern
extra_kwargs:
method: "query_major"
directory: "bridge_api_patterns/list_communities"
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