Provide better debugging means

This is just to assist debugging of the runners, so that
we can grab in a case needed the screen and stderr .

* there's a script t/03_debug.t.DISABLED which needs to be renamed then
* it utilises IPC::Run3
- also showing the PATH is added for both runners
- Readme amended accordingly
This commit is contained in:
Dirk
2026-06-09 13:43:43 +02:00
parent c25a0ad491
commit 457f8fd0a0
4 changed files with 49 additions and 0 deletions
+3
View File
@@ -45,6 +45,8 @@ jobs:
printf "%s\n" "----------"
bash --version
printf "%s\n" "----------"
echo $PATH
printf "%s\n" "----------"
- name: Install perl modules
run: |
@@ -52,6 +54,7 @@ jobs:
cpanm --notest Data::Dumper
cpanm --notest JSON
cpanm --notest Text::Diff
cpanm --notest IPC::Run3
- name: run it
run: |
+3
View File
@@ -51,6 +51,8 @@ jobs:
printf "%s\n" "----------"
bash --version
printf "%s\n" "----------"
echo $PATH
printf "%s\n" "----------"
- name: Install perl modules
run: |
@@ -58,6 +60,7 @@ jobs:
cpanm --notest Data::Dumper
cpanm --notest JSON
cpanm --notest Text::Diff
cpanm --notest IPC::Run3
- name: run it
run: |
+39
View File
@@ -0,0 +1,39 @@
#!/usr/bin/env perl
# Example for debugging what the runners do, here MacOS only
# (we used that before), To get output on the screen it's
# needed to encapsulate the functions you want to debug with
# set -x/+x and comment the last function @ 00_testssl_help.t
use strict;
use Test::More;
use IPC::Run3;
my $os="$^O";
my $prg="./testssl.sh";
my $check2run ="-p";
my $uri="testssl.sh";
my $stdout = '';
my $stderr = '';
# if ( $os eq "darwin" ){
printf "%s\n", "testing MacOS ";
run3(["/bin/bash", $prg, $check2run, $uri], \undef, \$stdout, \$stderr);
print STDERR $stderr;
print STDOUT $stdout;
# } elsif ( $os eq "linux" ){
# printf "skipped check on Linux\n\n";
#}
# Use the following when you want to run everything below ~/t
# done_testing();
# This stops, no further checks within ~/t will run:
BAIL_OUT("Fundamental check done, aborting");
# vim:ts=5:sw=5:expandtab
+4
View File
@@ -8,3 +8,7 @@
Please help to write CI tests! Documentation can be found [here](https://perldoc.perl.org/Test/More.html).
You can consult the existing code here. Feel free to use `10_baseline_ipv4_http.t` or `12_diff_opensslversions.t` as a
template. The latter is newer and code is cleaner.
* `03_debug.t.DISABLED` is a handy tool when the runner is not in line with checks outside github. It provides debugging means
* IPv6 was (status 2025) not allowed, thus the file `11_baseline_ipv6_http.t.DISABLED` which can be renamed if that will change.