mirror of
https://github.com/YunoHost/package_check.git
synced 2024-09-03 20:06:20 +02:00
curl tests: fix default tests and display
This commit is contained in:
parent
a5b35d218d
commit
28b83f5f95
1 changed files with 3 additions and 3 deletions
|
@ -160,8 +160,8 @@ def run(tests):
|
||||||
|
|
||||||
|
|
||||||
def display_result(result):
|
def display_result(result):
|
||||||
if result["effective_url"] == result["url"]:
|
if result["effective_url"] != result["url"]:
|
||||||
print(f"URL : {result['url']} (redirected to -> {result['effective_url']})")
|
print(f"URL : {result['url']} (redirected to: {result['effective_url']})")
|
||||||
else:
|
else:
|
||||||
print(f"URL : {result['url']}")
|
print(f"URL : {result['url']}")
|
||||||
if result['code'] != 200:
|
if result['code'] != 200:
|
||||||
|
@ -181,7 +181,7 @@ def main():
|
||||||
|
|
||||||
tests = sys.stdin.read()
|
tests = sys.stdin.read()
|
||||||
|
|
||||||
if not tests:
|
if not tests.strip():
|
||||||
tests = "home.path = '/'"
|
tests = "home.path = '/'"
|
||||||
|
|
||||||
tests = toml.loads(tests)
|
tests = toml.loads(tests)
|
||||||
|
|
Loading…
Add table
Reference in a new issue