mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-09-21 02:08:12 +03:00
Meta: Use the new Shell features to improve run-tests-and-shutdown
Fixes two TODOs in that file :^)
This commit is contained in:
parent
13b65b632a
commit
1496b02203
Notes:
sideshowbarker
2024-07-18 21:39:38 +09:00
Author: https://github.com/alimpfard Commit: https://github.com/SerenityOS/serenity/commit/1496b022037 Pull-request: https://github.com/SerenityOS/serenity/pull/5652 Reviewed-by: https://github.com/ADKaster Reviewed-by: https://github.com/BenWiederhake
@ -2,9 +2,10 @@
|
||||
|
||||
echo "==== Running Tests on SerenityOS ===="
|
||||
|
||||
run() {
|
||||
run(index) {
|
||||
shift
|
||||
test_cmd=($*)
|
||||
echo "Running test -- $test_cmd"
|
||||
echo "Running test $index out of $count_of_all_tests -- $test_cmd"
|
||||
if $test_cmd {
|
||||
echo "::debug file=$test_cmd:: $test_cmd passed!"
|
||||
} else {
|
||||
@ -12,15 +13,14 @@ run() {
|
||||
}
|
||||
}
|
||||
|
||||
# TODO: It'd be nice to have a list+list op (as opposed to nest-on-in-another)
|
||||
# TODO: It'd be nice to have a list.length or enumerate(list) operation to allow terminal progress bar
|
||||
# TODO: test-web requires the window server
|
||||
system_tests=((test-js --show-progress=false) test-pthread test-compress /usr/Tests/LibM/test-math (test-crypto bigint -t))
|
||||
# FIXME: Running too much at once is likely to run into #5541. Remove commented out find below when stable
|
||||
all_tests=($system_tests) #$(find /usr/Tests -type f | grep -v Kernel | grep -v .inc | shuf))
|
||||
all_tests=${concat_lists $system_tests} #$(find /usr/Tests -type f | grep -v Kernel | grep -v .inc | shuf))
|
||||
count_of_all_tests=${length $all_tests}
|
||||
|
||||
for list in $all_tests {
|
||||
for $list { run $it }
|
||||
for index i cmd in $all_tests {
|
||||
run $(expr $i + 1) $cmd
|
||||
}
|
||||
|
||||
echo "==== Done running tests ===="
|
||||
|
Loading…
Reference in New Issue
Block a user