aboutsummaryrefslogtreecommitdiffstats
path: root/t
diff options
context:
space:
mode:
authorMatt Selsky <selsky@columbia.edu>2012-12-01 02:18:21 +0100
committerFrédéric Buclin <LpSolit@gmail.com>2012-12-01 02:18:21 +0100
commitb4adb1ab4c7e3c34d64b92530602ca38144f249b (patch)
treee1c088d37f09b8b54bbde313b60f1ff874f2cf78 /t
parent45f67203b182d6a64b9708a22d82a21e455deb74 (diff)
downloadbugs-b4adb1ab4c7e3c34d64b92530602ca38144f249b.tar
bugs-b4adb1ab4c7e3c34d64b92530602ca38144f249b.tar.gz
bugs-b4adb1ab4c7e3c34d64b92530602ca38144f249b.tar.bz2
bugs-b4adb1ab4c7e3c34d64b92530602ca38144f249b.tar.xz
bugs-b4adb1ab4c7e3c34d64b92530602ca38144f249b.zip
Bug 787668: Use |use parent| instead of |use base|
r/a=LpSolit
Diffstat (limited to 't')
-rw-r--r--t/010dependencies.t4
-rw-r--r--t/Support/Templates.pm2
2 files changed, 3 insertions, 3 deletions
diff --git a/t/010dependencies.t b/t/010dependencies.t
index d84688a7e..89a26ba5e 100644
--- a/t/010dependencies.t
+++ b/t/010dependencies.t
@@ -27,7 +27,7 @@ use constant MODULE_REGEX => qr/
['"]?
([\w:\.\\]+)
/x;
-use constant BASE_REGEX => qr/^use base qw\(([^\)]+)/;
+use constant BASE_REGEX => qr/^use (?:base|parent) (?:-norequire, )?qw\(([^\)]+)/;
# Extract all Perl modules.
foreach my $file (@Support::Files::testitems) {
@@ -59,7 +59,7 @@ foreach my $module (keys %mods) {
}
elsif ($line =~ BASE_REGEX or $line =~ MODULE_REGEX) {
my $used_string = $1;
- # "use base" can have multiple modules
+ # "use base"/"use parent" can have multiple modules
my @used_array = split(/\s+/, $used_string);
foreach my $used (@used_array) {
next if $used !~ /^Bugzilla/;
diff --git a/t/Support/Templates.pm b/t/Support/Templates.pm
index a28ec8759..c9a528e9f 100644
--- a/t/Support/Templates.pm
+++ b/t/Support/Templates.pm
@@ -10,7 +10,7 @@ package Support::Templates;
use strict;
use lib 't';
-use base qw(Exporter);
+use parent qw(Exporter);
@Support::Templates::EXPORT =
qw(@languages @include_paths $english_default_include_path
%include_path @referenced_files %actual_files $num_actual_files);