mirror of
https://github.com/YunoHost/package_check.git
synced 2024-09-03 20:06:20 +02:00
Display the name of extra test serie
This commit is contained in:
parent
5952eb8feb
commit
ce3d4ea776
2 changed files with 10 additions and 2 deletions
|
@ -174,9 +174,11 @@ for test in tests:
|
||||||
if test["test_arg"]:
|
if test["test_arg"]:
|
||||||
test_display_name += " (%s)" % test["test_arg"][:8]
|
test_display_name += " (%s)" % test["test_arg"][:8]
|
||||||
test_display_name += ":"
|
test_display_name += ":"
|
||||||
|
if test["test_serie"] != "default":
|
||||||
|
test_display_name = "(%s)" % test["test_serie"][:15]
|
||||||
|
|
||||||
result = OK if test["results"]["main_result"] == "success" else FAIL
|
result = OK if test["results"]["main_result"] == "success" else FAIL
|
||||||
print("{test: <25}{result}".format(test=test_display_name, result=result))
|
print("{test: <30}{result}".format(test=test_display_name, result=result))
|
||||||
|
|
||||||
print()
|
print()
|
||||||
print("Level results")
|
print("Level results")
|
||||||
|
@ -210,6 +212,7 @@ summary = {
|
||||||
"tests": [{
|
"tests": [{
|
||||||
"test_type": t["test_type"],
|
"test_type": t["test_type"],
|
||||||
"test_arg": t["test_arg"],
|
"test_arg": t["test_arg"],
|
||||||
|
"test_serie": t["test_serie"],
|
||||||
"main_result": t["results"]["main_result"]
|
"main_result": t["results"]["main_result"]
|
||||||
} for t in tests],
|
} for t in tests],
|
||||||
"levels": {level.level: level.passed for level in levels[1:]},
|
"levels": {level.level: level.passed for level in levels[1:]},
|
||||||
|
|
|
@ -363,9 +363,14 @@ break_before_continue () {
|
||||||
|
|
||||||
start_test () {
|
start_test () {
|
||||||
|
|
||||||
|
local current_test_serie=$(jq -r '.test_serie' $testfile)
|
||||||
|
[[ "$current_test_serie" != "default" ]] \
|
||||||
|
&& current_test_serie="($current_test_serie)"
|
||||||
|
|| current_test_serie=""
|
||||||
|
|
||||||
total_number_of_test=$(ls $TEST_CONTEXT/tests/*.json | wc -l)
|
total_number_of_test=$(ls $TEST_CONTEXT/tests/*.json | wc -l)
|
||||||
|
|
||||||
log_title "$1 [Test $current_test_number/$total_number_of_test]"
|
log_title "$current_test_serie $1 [Test $current_test_number/$total_number_of_test]"
|
||||||
|
|
||||||
# Increment the value of the current test
|
# Increment the value of the current test
|
||||||
current_test_number=$((current_test_number+1))
|
current_test_number=$((current_test_number+1))
|
||||||
|
|
Loading…
Add table
Reference in a new issue