[Perl] DAQ system for the FAPG.
1
use Mojo::Base -strict;
2
3
use Test2::V0;
4
5
use FindBin;
6
7
my @command = (
8
'node', '--experimental-vm-modules',
9
'--test', "${FindBin::Bin}/js/frontend.test.cjs",
10
);
11
12
open my $output, '-|', @command
13
or plan skip_all => 'node is unavailable';
14
my $diagnostics = do { local $/; <$output> };
15
close $output;
16
my $exit_status = $? >> 8;
17
18
diag $diagnostics if $exit_status;
19
is $exit_status, 0, 'frontend unit tests pass';
20
21
done_testing;
22