Skip to content

Instantly share code, notes, and snippets.

@magnolia-k
Created August 11, 2014 15:54
Show Gist options
  • Save magnolia-k/a7a92928a6de0db37abf to your computer and use it in GitHub Desktop.
Save magnolia-k/a7a92928a6de0db37abf to your computer and use it in GitHub Desktop.
use strict;
use warnings;
use utf8;
use Test::More;
binmode('STDOUT', ':encoding(cp932)');
binmode('STDERR', ':encoding(cp932)');
tap_encoding 'cp932';
ok(0, 'テスト失敗');
print "テストではないです\n";
subtest 'subtest' => sub {
ok(0, 'サブテスト失敗');
print "サブテストではないです\n";
};
print "テストではないです\n";
done_testing;
> perl -Ilib .\テスト.t
not ok 1 - テスト失敗
# Failed test 'テスト失敗'
# at ..\テスト.t line 14.
テストではないです
# Subtest: subtest
not ok 1 - サブテスト失敗
# Failed test 'サブテスト失敗'
# at ..\テスト.t line 19.
サブテストではないです
1..1
# Looks like you failed 1 test of 1.
not ok 2 - subtest
# Failed test 'subtest'
# at ..\テスト.t line 21.
テストではないです
1..2
# Looks like you failed 2 tests of 2.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment