Skip to content
Snippets Groups Projects
Commit f093ee00 authored by Bartek Wrona's avatar Bartek Wrona
Browse files

Merge branch 'mt-new-tests' into 'master'

New tests

See merge request !172
parents ba07926d c50665c8
No related branches found
No related tags found
1 merge request!172New tests
Showing
with 2792 additions and 0 deletions
[
{
"active_votes": [],
"author": "nkdk",
"author_payout_value": "0.000 HBD",
"author_reputation": 25.0,
"beneficiaries": [],
"blacklists": [],
"body": "https://media.giphy.com/media/26vUNS0kPuf3FfJEA/giphy.gif",
"category": "gif",
"children": 0,
"created": "2016-05-12T17:43:30",
"curator_payout_value": "0.000 HBD",
"depth": 0,
"is_paidout": true,
"json_metadata": {},
"max_accepted_payout": "1000000.000 HBD",
"net_rshares": 0,
"payout": 0.0,
"payout_at": "2016-08-26T03:00:03",
"pending_payout_value": "0.000 HBD",
"percent_steem_dollars": 10000,
"permlink": "i-wonder-what-makes-it-turn",
"post_id": 4045,
"promoted": "0.000 HBD",
"replies": [],
"stats": {
"flag_weight": 0.0,
"gray": false,
"hide": false,
"total_votes": 0
},
"title": "I wonder what makes it turn?",
"updated": "2016-05-12T17:43:30",
"url": "/gif/@nkdk/i-wonder-what-makes-it-turn"
},
{
"active_votes": [
{
"rshares": "-18995393857212",
"voter": "dantheman"
}
],
"author": "nkdk",
"author_payout_value": "0.000 HBD",
"author_reputation": 25.0,
"beneficiaries": [],
"blacklists": [],
"body": "http://66.media.tumblr.com/8019b2a57408f4c7c1f48a8e67618d0b/tumblr_o70ltkru8Z1rte5gyo1_500.gif",
"category": "gif",
"children": 0,
"created": "2016-05-12T17:32:36",
"curator_payout_value": "0.000 HBD",
"depth": 0,
"is_paidout": true,
"json_metadata": {},
"max_accepted_payout": "1000000.000 HBD",
"net_rshares": -18995393857212,
"payout": 0.0,
"payout_at": "2016-08-03T00:00:06",
"pending_payout_value": "0.000 HBD",
"percent_steem_dollars": 10000,
"permlink": "magenta-ball",
"post_id": 4041,
"promoted": "0.000 HBD",
"replies": [],
"stats": {
"flag_weight": 3.0,
"gray": false,
"hide": false,
"total_votes": 1
},
"title": "magenta ball",
"updated": "2016-05-12T17:32:36",
"url": "/gif/@nkdk/magenta-ball"
},
{
"active_votes": [
{
"rshares": "2916665887200",
"voter": "lafona-miner"
},
{
"rshares": "226247507009",
"voter": "lafona"
},
{
"rshares": "2698571778435",
"voter": "nextgencrypto"
},
{
"rshares": "3936756300",
"voter": "bunny"
},
{
"rshares": "23937985389",
"voter": "pheonike"
},
{
"rshares": "71142139563",
"voter": "donkeypong"
},
{
"rshares": "691600921",
"voter": "steemrollin"
},
{
"rshares": "7239535072",
"voter": "bangking"
},
{
"rshares": "584711329",
"voter": "steampunkpowered"
},
{
"rshares": "463576832",
"voter": "bobsunday"
},
{
"rshares": "598222801",
"voter": "valtr"
},
{
"rshares": "52317363",
"voter": "summersolstice"
},
{
"rshares": "569159751",
"voter": "gregory-f"
}
],
"author": "nkdk",
"author_payout_value": "2.364 HBD",
"author_reputation": 25.0,
"beneficiaries": [],
"blacklists": [],
"body": "[[embed url=https://www.youtube.com/watch?v=qZI6lGSq1gU]",
"category": "video",
"children": 4,
"created": "2016-05-12T17:22:18",
"curator_payout_value": "2.364 HBD",
"depth": 0,
"is_paidout": true,
"json_metadata": {},
"max_accepted_payout": "1000000.000 HBD",
"net_rshares": 5950701177965,
"payout": 4.728,
"payout_at": "2016-08-03T00:00:06",
"pending_payout_value": "0.000 HBD",
"percent_steem_dollars": 10000,
"permlink": "thermosolar-hive-healthy-bees-healthy-honey",
"post_id": 4036,
"promoted": "0.000 HBD",
"replies": [],
"stats": {
"flag_weight": 0.0,
"gray": false,
"hide": false,
"total_votes": 13
},
"title": "Thermosolar Hive: healthy bees & healthy honey ",
"updated": "2016-05-12T17:22:18",
"url": "/video/@nkdk/thermosolar-hive-healthy-bees-healthy-honey"
},
{
"active_votes": [
{
"rshares": "-47756400000000",
"voter": "dan"
}
],
"author": "nkdk",
"author_payout_value": "0.000 HBD",
"author_reputation": 25.0,
"beneficiaries": [],
"blacklists": [],
"body": "Un vecino de Arenas de San Pedro ha fallecido al ahogarse en el r\u00edo Arenal, al caerse al cauce cuando intentaba rescatar a su perro, que se hab\u00eda precipitado al agua. \n\n\nSe trata de Ricardo Santos, de 52 a\u00f1os y conocido en Arenas como miembro de la Asociaci\u00f3n de Amigos del Palacio de La Mosquera y fue n\u00famero dos en la lista municipal Por Arenas en 2015.\n\n\n El hecho ocurri\u00f3 al caerse al r\u00edo a la altura del Pol\u00edgono El Martinete, aguas abajo del Arenal, un cauce con abundante caudal y fuerte corriente tras las intensas precipitaciones de los \u00faltimos d\u00edas.\n\n\n La v\u00edctima ha intentado rescatar a su perro de una corriente que le arrastr\u00f3 y que hizo que se le perdiera de vista, seg\u00fan la llamada que alert\u00f3 al Servicio de Emergencias 112, realizada por un amigo que le acompa\u00f1aba en su paseo por la orilla del r\u00edo Arenal.\n\n\n Hasta el lugar del hecho acudieron efectivos de Polic\u00eda Local, Guardia Civil y de Protecci\u00f3n Civil, que para lograr extraer el cuerpo del fallecido tuvieron que amarrarse a un \u00e1rbol para evitar ser arrastrados por la corriente en un lugar agreste y con \"muchas piedras.\n\n\n Tras realizarle, sin \u00e9xito, las labores de recuperaci\u00f3n cardiopulmonar, los facultativos de Sacyl desplazados a la zona s\u00f3lo pudieron certificar el fallecimiento.",
"category": "news",
"children": 1,
"created": "2016-05-12T17:10:39",
"curator_payout_value": "0.000 HBD",
"depth": 0,
"is_paidout": true,
"json_metadata": {},
"max_accepted_payout": "1000000.000 HBD",
"net_rshares": -47756400000000,
"payout": 0.0,
"payout_at": "2016-08-03T00:00:06",
"pending_payout_value": "0.000 HBD",
"percent_steem_dollars": 10000,
"permlink": "muere-ahogado-en-arenas-al-intentar-rescatar-a-su-perro",
"post_id": 4028,
"promoted": "0.000 HBD",
"replies": [],
"stats": {
"flag_weight": 4.0,
"gray": false,
"hide": false,
"total_votes": 1
},
"title": "Muere ahogado en Arenas al intentar rescatar a su perro",
"updated": "2016-05-12T17:10:39",
"url": "/news/@nkdk/muere-ahogado-en-arenas-al-intentar-rescatar-a-su-perro"
}
]
[
{
"active_votes": [],
"author": "nkdk",
"author_payout_value": "0.000 HBD",
"author_reputation": 65.67,
"beneficiaries": [],
"blacklists": [],
"body": "https://media.giphy.com/media/26vUNS0kPuf3FfJEA/giphy.gif",
"category": "gif",
"children": 0,
"created": "2016-05-12T17:43:30",
"curator_payout_value": "0.000 HBD",
"depth": 0,
"is_paidout": true,
"json_metadata": {},
"max_accepted_payout": "1000000.000 HBD",
"net_rshares": 0,
"payout": 0.0,
"payout_at": "2016-08-26T03:00:03",
"pending_payout_value": "0.000 HBD",
"percent_hbd": 10000,
"permlink": "i-wonder-what-makes-it-turn",
"post_id": 5243,
"promoted": "0.000 HBD",
"replies": [],
"stats": {
"flag_weight": 0.0,
"gray": false,
"hide": false,
"total_votes": 0
},
"title": "I wonder what makes it turn?",
"updated": "2016-05-12T17:43:30",
"url": "/gif/@nkdk/i-wonder-what-makes-it-turn"
},
{
"active_votes": [
{
"rshares": -18995393857212,
"voter": "dantheman"
}
],
"author": "nkdk",
"author_payout_value": "0.000 HBD",
"author_reputation": 65.67,
"beneficiaries": [],
"blacklists": [],
"body": "http://66.media.tumblr.com/8019b2a57408f4c7c1f48a8e67618d0b/tumblr_o70ltkru8Z1rte5gyo1_500.gif",
"category": "gif",
"children": 0,
"created": "2016-05-12T17:32:36",
"curator_payout_value": "0.000 HBD",
"depth": 0,
"is_paidout": true,
"json_metadata": {},
"max_accepted_payout": "1000000.000 HBD",
"net_rshares": -18995393857212,
"payout": 0.0,
"payout_at": "2016-08-03T00:00:06",
"pending_payout_value": "0.000 HBD",
"percent_hbd": 10000,
"permlink": "magenta-ball",
"post_id": 5239,
"promoted": "0.000 HBD",
"replies": [],
"stats": {
"flag_weight": 3.0,
"gray": false,
"hide": false,
"total_votes": 1
},
"title": "magenta ball",
"updated": "2016-05-12T17:32:36",
"url": "/gif/@nkdk/magenta-ball"
},
{
"active_votes": [
{
"rshares": 2916665887200,
"voter": "lafona-miner"
},
{
"rshares": 226247507009,
"voter": "lafona"
},
{
"rshares": 2698571778435,
"voter": "nextgencrypto"
},
{
"rshares": 3936756300,
"voter": "bunny"
},
{
"rshares": 23937985389,
"voter": "pheonike"
},
{
"rshares": 71142139563,
"voter": "donkeypong"
},
{
"rshares": 691600921,
"voter": "steemrollin"
},
{
"rshares": 7239535072,
"voter": "bangking"
},
{
"rshares": 584711329,
"voter": "steampunkpowered"
},
{
"rshares": 463576832,
"voter": "bobsunday"
},
{
"rshares": 598222801,
"voter": "valtr"
},
{
"rshares": 52317363,
"voter": "summersolstice"
},
{
"rshares": 569159751,
"voter": "gregory-f"
}
],
"author": "nkdk",
"author_payout_value": "2.364 HBD",
"author_reputation": 65.67,
"beneficiaries": [],
"blacklists": [],
"body": "[[embed url=https://www.youtube.com/watch?v=qZI6lGSq1gU]",
"category": "video",
"children": 4,
"created": "2016-05-12T17:22:18",
"curator_payout_value": "2.364 HBD",
"depth": 0,
"is_paidout": true,
"json_metadata": {},
"max_accepted_payout": "1000000.000 HBD",
"net_rshares": 5950701177965,
"payout": 4.728,
"payout_at": "2016-08-03T00:00:06",
"pending_payout_value": "0.000 HBD",
"percent_hbd": 10000,
"permlink": "thermosolar-hive-healthy-bees-healthy-honey",
"post_id": 5234,
"promoted": "0.000 HBD",
"replies": [],
"stats": {
"flag_weight": 0.0,
"gray": false,
"hide": false,
"total_votes": 13
},
"title": "Thermosolar Hive: healthy bees & healthy honey ",
"updated": "2016-05-12T17:22:18",
"url": "/video/@nkdk/thermosolar-hive-healthy-bees-healthy-honey"
},
{
"active_votes": [
{
"rshares": -47756400000000,
"voter": "dan"
}
],
"author": "nkdk",
"author_payout_value": "0.000 HBD",
"author_reputation": 65.67,
"beneficiaries": [],
"blacklists": [],
"body": "Un vecino de Arenas de San Pedro ha fallecido al ahogarse en el r\u00edo Arenal, al caerse al cauce cuando intentaba rescatar a su perro, que se hab\u00eda precipitado al agua. \n\n\nSe trata de Ricardo Santos, de 52 a\u00f1os y conocido en Arenas como miembro de la Asociaci\u00f3n de Amigos del Palacio de La Mosquera y fue n\u00famero dos en la lista municipal Por Arenas en 2015.\n\n\n El hecho ocurri\u00f3 al caerse al r\u00edo a la altura del Pol\u00edgono El Martinete, aguas abajo del Arenal, un cauce con abundante caudal y fuerte corriente tras las intensas precipitaciones de los \u00faltimos d\u00edas.\n\n\n La v\u00edctima ha intentado rescatar a su perro de una corriente que le arrastr\u00f3 y que hizo que se le perdiera de vista, seg\u00fan la llamada que alert\u00f3 al Servicio de Emergencias 112, realizada por un amigo que le acompa\u00f1aba en su paseo por la orilla del r\u00edo Arenal.\n\n\n Hasta el lugar del hecho acudieron efectivos de Polic\u00eda Local, Guardia Civil y de Protecci\u00f3n Civil, que para lograr extraer el cuerpo del fallecido tuvieron que amarrarse a un \u00e1rbol para evitar ser arrastrados por la corriente en un lugar agreste y con \"muchas piedras.\n\n\n Tras realizarle, sin \u00e9xito, las labores de recuperaci\u00f3n cardiopulmonar, los facultativos de Sacyl desplazados a la zona s\u00f3lo pudieron certificar el fallecimiento.",
"category": "news",
"children": 1,
"created": "2016-05-12T17:10:39",
"curator_payout_value": "0.000 HBD",
"depth": 0,
"is_paidout": true,
"json_metadata": {},
"max_accepted_payout": "1000000.000 HBD",
"net_rshares": -47756400000000,
"payout": 0.0,
"payout_at": "2016-08-03T00:00:06",
"pending_payout_value": "0.000 HBD",
"percent_hbd": 10000,
"permlink": "muere-ahogado-en-arenas-al-intentar-rescatar-a-su-perro",
"post_id": 5218,
"promoted": "0.000 HBD",
"replies": [],
"stats": {
"flag_weight": 4.0,
"gray": false,
"hide": false,
"total_votes": 1
},
"title": "Muere ahogado en Arenas al intentar rescatar a su perro",
"updated": "2016-05-12T17:10:39",
"url": "/news/@nkdk/muere-ahogado-en-arenas-al-intentar-rescatar-a-su-perro"
}
]
---
test_name: Hivemind bridge_api.get_account_posts
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":"blog",
"account":"nkdk",
"limit":20,
"start_author":"nkdk",
"start_permlink":"i-wonder-what-makes-it-turn"
}
response:
status_code: 200
verify_response_with:
function: validate_response:compare_response_with_pattern
extra_kwargs:
method: "nkdk"
directory: "bridge_api_patterns/get_account_posts/blog"
This diff is collapsed.
---
test_name: Hivemind bridge_api.get_account_posts
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":"blog",
"account":"roadscape",
"limit":5,
"start_author":"roadscape",
"start_permlink":"steemd-update-3"
}
response:
status_code: 200
verify_response_with:
function: validate_response:compare_response_with_pattern
extra_kwargs:
method: "roadscape"
directory: "bridge_api_patterns/get_account_posts/blog"
---
test_name: Hivemind condenser_api.get_followers patterns test
marks:
- patterntest
includes:
- !include ../../common.yaml
stages:
- name: get_followers
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_followers"
params: {"account":"letritbt","start":"letritbt","limit":3}
response:
status_code: 200
verify_response_with:
function: validate_response:compare_response_with_pattern
extra_kwargs:
method: "the_same_account_start"
directory: "condenser_api_negative/get_followers"
---
test_name: Hivemind condenser_api.get_followers patterns test
marks:
- patterntest
includes:
- !include ../../common.yaml
stages:
- name: get_followers
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_followers"
params: {"account":"roadscape","start":"roadscape","limit":3}
response:
status_code: 200
verify_response_with:
function: validate_response:compare_response_with_pattern
extra_kwargs:
method: "the_same_account_start"
directory: "condenser_api_negative/get_followers"
{
"code": -32000,
"data": "ValueError: list.remove(x): x not in list",
"message": "Server error"
}
{
"code": -31999,
"data": "Post christiaan/woman-sets-her-husband-on-fire-for-raping-her-7-year-old-daughter was deleted 1 time(s)",
"message": "Invalid parameters"
}
---
test_name: Hivemind condenser_api.get_reblogged_by patterns test
marks:
- patterntest # bug in old HM
includes:
- !include ../../common.yaml
stages:
- name: get_reblogged_by
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_reblogged_by"
params: {"author":"christiaan","permlink":"woman-sets-her-husband-on-fire-for-raping-her-7-year-old-daughter"}
response:
status_code: 200
verify_response_with:
function: validate_response:compare_response_with_pattern
extra_kwargs:
method: "deleted_post"
directory: "condenser_api_negative/get_reblogged_by"
error_response: true
\ No newline at end of file
{
"code": -32000,
"data": "ValueError: list.remove(x): x not in list",
"message": "Server error"
}
{
"code": -31999,
"data": "Post gardenlady/re-steemychicken1-re-andrarchy-steemit-slogan-competition-20160625t015635752z was deleted 1 time(s)",
"message": "Invalid parameters"
}
---
test_name: Hivemind condenser_api.get_reblogged_by patterns test
marks:
- patterntest # bug in old HM
includes:
- !include ../../common.yaml
stages:
- name: get_reblogged_by
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_reblogged_by"
params: {"author":"gardenlady","permlink":"re-steemychicken1-re-andrarchy-steemit-slogan-competition-20160625t015635752z"}
response:
status_code: 200
verify_response_with:
function: validate_response:compare_response_with_pattern
extra_kwargs:
method: "deleted_reply"
directory: "condenser_api_negative/get_reblogged_by"
error_response: true
\ No newline at end of file
{
"code": -32602,
"data": "post not found",
"message": "Invalid parameters"
}
{
"code": -32602,
"data": "Post roadscape/banana-cherry does not exist",
"message": "Invalid parameters"
}
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