Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

parse.t failed on ja locale #4

Merged
merged 1 commit into from

2 participants

@hiratara

I ran "make test" and got following lines.

# Failed test at t/parse.t line 15.
# '/tmp/cpanfile/cpanfile: そのようなファイルやディレクトリはありません at /tmp/cpanfile/blib/lib/Module/CPANfile.pm line 67.
# '
# doesn't match '(?-xism:No such file)'

My patch fixed this issue.

@miyagawa miyagawa merged commit 9bbac2a into miyagawa:master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Jul 30, 2012
  1. @hiratara
This page is out of date. Refresh to see the latest.
Showing with 5 additions and 0 deletions.
  1. +5 −0 t/parse.t
View
5 t/parse.t
@@ -3,16 +3,21 @@ use Module::CPANfile;
use Test::More;
use Cwd;
use File::Basename qw(dirname);
+use POSIX qw(locale_h);
use t::Utils;
eval { require CPAN::Meta::Prereqs; 1 }
or plan skip_all => "CPAN::Meta::Prereqs not found";
{
+ # Use the traditional UNIX system locale to check the error message string.
+ my $old_locale = setlocale(LC_ALL);
+ setlocale(LC_ALL, 'C');
eval {
my $file = Module::CPANfile->load;
};
like $@, qr/No such file/;
+ setlocale(LC_ALL, $old_locale);
}
{
Something went wrong with that request. Please try again.