Update KAT definition for real login test, error handling and indexer testing logic (#1569)

* Update KAT definition for real login test

* Add error handling to KAT definition's login

* Even better error handling...

Sorry for the inelegant successive commits

* Add better test behaviour for KAT

Added some logic so tests return results. Previously did a search with an empty string which would return no results. NB : it does test with "torrents.php?search=%22%22" but that's not an issue, the parameter is ignored on that page.
This commit is contained in:
thebluepotato
2017-07-19 19:11:29 +02:00
committed by chibidev
parent f0da6ce247
commit a07bffa773

View File

@@ -95,15 +95,18 @@
login:
method: post
path: "new/account-login.php"
path: "/new/account-login.php"
inputs:
username: "{{ .Config.username }}"
passkey: "{{ .Config.passkey }}"
error:
- selector: font.error:contains("Access Denied")
test:
path: index.php
path: "/new/index.php"
selector: a[href="account-logout.php"]
search:
path: "/new/torrents-search.php"
path: "/new/{{if .Query.Keywords}}torrents-search.php{{else}}torrents.php{{end}}"
inputs:
$raw: "{{range .Categories}}c{{.}}=1&{{end}}"
search: "\"{{ .Query.Keywords }}\""