diff options
author | Matthew Somerville <matthew-github@dracos.co.uk> | 2018-10-04 13:39:31 +0100 |
---|---|---|
committer | Matthew Somerville <matthew-github@dracos.co.uk> | 2018-10-04 13:39:31 +0100 |
commit | a123e7da22e9dbf8d98d15287526d070ab15bf15 (patch) | |
tree | 34d6d1170fe594e22b43290c6d1e155aad044e57 | |
parent | b816cd81fea58adcad5ae216b4dfe9030dad40aa (diff) |
Add perl 5.26/5.28 support.
Upgrade a couple of modules, deal with '.' not present in @INC,
captures returning undef rather than '', and a test.
-rw-r--r-- | CHANGELOG.md | 3 | ||||
-rwxr-xr-x | bin/run-tests | 6 | ||||
-rw-r--r-- | cpanfile | 2 | ||||
-rw-r--r-- | cpanfile.snapshot | 13 | ||||
-rw-r--r-- | perllib/FixMyStreet/App/Controller/Photo.pm | 3 | ||||
-rw-r--r-- | t/i18n.t | 1 |
6 files changed, 20 insertions, 8 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md index 602bae632..6f7fbacfc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,7 +1,10 @@ ## Releases * Unreleased + - Front end improvements: - Clearer relocation options while you’re reporting a problem #2238 + - Bugfixes: + - Add perl 5.26/5.28 support. * v2.4.1 (2nd October 2018) - New features: diff --git a/bin/run-tests b/bin/run-tests index c384516c8..de495dd05 100755 --- a/bin/run-tests +++ b/bin/run-tests @@ -1,13 +1,17 @@ #!/usr/bin/env perl use strict; use warnings; +my $d; BEGIN { use File::Basename qw(dirname); use File::Spec; - my $d = dirname(File::Spec->rel2abs($0)); + $d = dirname(File::Spec->rel2abs($0)); require "$d/../setenv.pl"; } +# So the t::Mock:: modules can be found +$ENV{PERL5LIB} = "$d/..:$ENV{PERL5LIB}"; + use FixMyStreet::TestAppProve; =head1 NAME @@ -14,6 +14,8 @@ requires 'aliased', '0.34'; requires 'Net::SSLeay', '1.81'; requires 'Module::ScanDeps', '1.24'; requires 'CGI', '4.38'; +requires 'Lingua::EN::Tagger', '0.27'; +requires 'Params::Classify', '0.014'; # Catalyst itself, and modules/plugins used requires 'Catalyst', '5.80031'; diff --git a/cpanfile.snapshot b/cpanfile.snapshot index aa00250ae..ef37a146c 100644 --- a/cpanfile.snapshot +++ b/cpanfile.snapshot @@ -3852,10 +3852,10 @@ DISTRIBUTIONS Try::Tiny 0 strict 0 warnings 0 - Lingua-EN-Tagger-0.23 - pathname: A/AC/ACOBURN/Lingua-EN-Tagger-0.23.tar.gz + Lingua-EN-Tagger-0.30 + pathname: A/AC/ACOBURN/Lingua-EN-Tagger-0.30.tar.gz provides: - Lingua::EN::Tagger 0.23 + Lingua::EN::Tagger 0.30 requirements: ExtUtils::MakeMaker 0 File::Spec 0.84 @@ -5463,13 +5463,12 @@ DISTRIBUTIONS requirements: ExtUtils::MakeMaker 0 perl 5.008001 - Params-Classify-0.013 - pathname: Z/ZE/ZEFRAM/Params-Classify-0.013.tar.gz + Params-Classify-0.015 + pathname: Z/ZE/ZEFRAM/Params-Classify-0.015.tar.gz provides: - Params::Classify 0.013 + Params::Classify 0.015 requirements: Exporter 0 - ExtUtils::ParseXS 2.2006 Module::Build 0 Scalar::Util 1.01 Test::More 0 diff --git a/perllib/FixMyStreet/App/Controller/Photo.pm b/perllib/FixMyStreet/App/Controller/Photo.pm index 1884b9f26..4ae25db24 100644 --- a/perllib/FixMyStreet/App/Controller/Photo.pm +++ b/perllib/FixMyStreet/App/Controller/Photo.pm @@ -47,6 +47,9 @@ sub index :LocalRegex('^(c/)?([1-9]\d*)(?:\.(\d+))?(?:\.(full|tn|fp))?\.(?:jpeg| my ( $self, $c ) = @_; my ( $is_update, $id, $photo_number, $size ) = @{ $c->req->captures }; + $photo_number ||= 0; + $size ||= ''; + my $item; if ( $is_update ) { ($item) = $c->model('DB::Comment')->search( { @@ -1,5 +1,6 @@ use strict; use warnings; +use utf8; use Test::More; |