adventofcode/2024/04/test.t

23 lines
404 B
Perl
Raw Permalink Normal View History

2024-12-04 20:46:05 +00:00
use lib qw~ . ~;
use Part1;
use Part2;
use Test2::V0;
use Path::Tiny;
my $sample = Part1::read_file( path('sample')->lines );
my $input= Part1::read_file( path('input')->lines );
subtest 'part 1' => sub {
is Part1::solve($sample) => 18;
is Part1::solve($input) => 2336;
};
subtest 'part 2' => sub {
is Part2::solve($sample) => 9;
is Part2::solve($input) => 1831;
};
done_testing();