SecBSD's official ports repository

This commit is contained in:
purplerain 2023-08-16 22:26:55 +00:00
commit 2c0afcbbf3
Signed by: purplerain
GPG key ID: F42C07F07E2E35B7
64331 changed files with 5339189 additions and 0 deletions

View file

@ -0,0 +1,14 @@
Newer Perl returns hash keys in random order, make error deterministic.
Index: lib/Test/Unit/Assert.pm
--- lib/Test/Unit/Assert.pm.orig
+++ lib/Test/Unit/Assert.pm
@@ -315,7 +315,7 @@ sub _eq_hash {
my $ok = 1;
my $bigger = keys %$a1 > keys %$a2 ? $a1 : $a2;
- foreach my $k (keys %$bigger) {
+ foreach my $k (sort keys %$bigger) {
my $e1 = exists $a1->{$k} ? $a1->{$k} : $DNE;
my $e2 = exists $a2->{$k} ? $a2->{$k} : $DNE;

View file

@ -0,0 +1,14 @@
Newer Perl does not allow defined with an array.
Index: lib/Test/Unit/TestCase.pm
--- lib/Test/Unit/TestCase.pm.orig
+++ lib/Test/Unit/TestCase.pm
@@ -103,7 +103,7 @@ sub list_tests {
my $class = ref($_[0]) || $_[0];
my @tests = ();
no strict 'refs';
- if (defined(@{"$class\::TESTS"})) {
+ if (@{"$class\::TESTS"}) {
push @tests, @{"$class\::TESTS"};
}
else {

View file

@ -0,0 +1,23 @@
Newer Perl prints regex modifiers differently.
Index: t/tlib/AssertTest.pm
--- t/tlib/AssertTest.pm.orig
+++ t/tlib/AssertTest.pm
@@ -70,7 +70,7 @@ sub test_assert {
'bang' => [ __LINE__, sub { shift->assert(0, 'bang') } ],
'bang' => [ __LINE__, sub { shift->assert('', 'bang') } ],
- "'qux' did not match /(?-xism:foo)/"
+ "'qux' did not match /(?^:foo)/"
=> [ __LINE__, sub { shift->assert(qr/foo/, 'qux') } ],
'bang' => [ __LINE__, sub { shift->assert(qr/foo/, 'qux', 'bang') } ],
'a ne b'=> [ __LINE__, sub { shift->assert($coderef, 'a', 'b') } ],
@@ -253,7 +253,7 @@ sub test_ok_not_equals {
q{expected '', got 'foo'} => [ 'foo', '' ],
q{expected 'foo', got ''} => [ '', 'foo' ],
q{expected 5, got 4} => [ $adder, 5 ],
- q{'foo' did not match /(?-xism:x)/} => [ 'foo', qr/x/ ],
+ q{'foo' did not match /(?^:x)/} => [ 'foo', qr/x/ ],
);
my @tests = ();
while (@checks) {