forked from pool/perl-Git-Repository
OBS-URL: https://build.opensuse.org/package/show/devel:languages:perl/perl-Git-Repository?expand=0&rev=17
55 lines
2.1 KiB
Diff
55 lines
2.1 KiB
Diff
Description: Add workaround for Git v2.30.0
|
|
which emits hints about a future change of the default branch name,
|
|
which cause the tests for no warnings to fail.
|
|
Origin: vendor
|
|
Bug: https://rt.cpan.org/Public/Bug/Display.html?id=133951
|
|
Bug-Debian: https://bugs.debian.org/978325
|
|
Forwarded: https://rt.cpan.org/Public/Bug/Display.html?id=133951
|
|
Author: gregor herrmann <gregoa@debian.org>
|
|
Last-Update: 2021-01-01
|
|
|
|
--- a/t/24-errors.t
|
|
+++ b/t/24-errors.t
|
|
@@ -57,7 +57,7 @@
|
|
my @tests = (
|
|
|
|
# empty repository
|
|
- { test_repo => [],
|
|
+ { test_repo => [ init => [ qw/--initial-branch master/ ] ],
|
|
cmd => [qw( log -1 )],
|
|
exit => 128,
|
|
dollar_at => qr/^fatal: (?:bad default revision 'HEAD' |your current branch 'master' does not have any commits yet)/,
|
|
@@ -142,7 +142,7 @@
|
|
|
|
# setup a repo with some 'fatal' options
|
|
# and override them in the call to run()
|
|
- { test_repo => [ git => { fatal => [ 1 .. 255 ] } ],
|
|
+ { test_repo => [ git => { fatal => [ 1 .. 255 ] }, init => [ qw/--initial-branch master/ ] ],
|
|
cmd => [ exit => 125, { git => $exit } ],
|
|
exit => 125,
|
|
dollar_at => qr/^fatal: unknown git error/,
|
|
@@ -157,7 +157,7 @@
|
|
push @tests, (
|
|
|
|
# FATALITY
|
|
- { test_repo => [ git => { fatal => [ 0 .. 255 ] } ],
|
|
+ { test_repo => [ git => { fatal => [ 0 .. 255 ] }, init => [ qw/--initial-branch master/ ] ],
|
|
cmd => ['version'],
|
|
exit => 0,
|
|
dollar_at => qr/^fatal: unknown git error/,
|
|
@@ -172,12 +172,12 @@
|
|
push @tests, (
|
|
|
|
# "!0" is a shortcut for 1..255
|
|
- { test_repo => [],
|
|
+ { test_repo => [ init => [ qw/--initial-branch master/ ] ],
|
|
cmd => [ exit => 140, { git => $exit, fatal => '!0' } ],
|
|
exit => 140,
|
|
dollar_at => qr/^fatal: unknown git error/,
|
|
},
|
|
- { test_repo => [ git => { fatal => '!0' } ],
|
|
+ { test_repo => [ git => { fatal => '!0' }, init => [ qw/--initial-branch master/ ] ],
|
|
cmd => [ exit => 141, { git => $exit } ],
|
|
exit => 141,
|
|
dollar_at => qr/^fatal: unknown git error/,
|