[libtest-bdd-cucumber-perl] 25/52: set encoding for output stream to utf8 since we output utf8 (features and results)
Intrigeri
intrigeri at moszumanska.debian.org
Thu Jun 19 10:18:34 UTC 2014
This is an automated email from the git hooks/post-receive script.
intrigeri pushed a commit to annotated tag 0.19
in repository libtest-bdd-cucumber-perl.
commit 2973d9eba769d91c6c0cc0e6535e783cf458e11c
Author: glauschwuffel <glauschwuffel at nomaden.org>
Date: Mon May 26 22:08:08 2014 +0200
set encoding for output stream to utf8 since we output utf8 (features and results)
---
lib/App/pherkin.pm | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/lib/App/pherkin.pm b/lib/App/pherkin.pm
index f7fc094..7e8b60a 100644
--- a/lib/App/pherkin.pm
+++ b/lib/App/pherkin.pm
@@ -50,6 +50,9 @@ Returns a L<Test::BDD::Cucumber::Model::Result> object for all steps run.
sub run {
my ( $self, @arguments ) = @_;
+ # localized features will have utf8 in them and options may output utf8 as well
+ binmode STDOUT, ':utf8';
+
my ($options, @feature_files) = $self->_process_arguments(@arguments);
my ( $executor, @features ) = Test::BDD::Cucumber::Loader->load(
@@ -156,7 +159,6 @@ sub _print_languages {
my $format= "| %-${max_code_length}s | %-${max_name_length}s | %-${max_native_length}s |\n";
for my $language (sort @languages) {
- binmode STDOUT, ':utf8';
my $langdef=langdef($language);
printf $format, $language, $langdef->{name}, $langdef->{native};
}
@@ -176,7 +178,6 @@ sub _print_langdef {
for my $keyword (qw(feature background scenario scenario_outline
examples given when then and but )) {
- binmode STDOUT, ':utf8';
printf $format, $keyword, $langdef->{$keyword};
}
exit;
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libtest-bdd-cucumber-perl.git
More information about the Pkg-perl-cvs-commits
mailing list