Skip to content

Commit

Permalink
Read in white/blacklist test files as utf-8 (#627)
Browse files Browse the repository at this point in the history
Was causing characters such as `£` to transform into another character, thus meaning tests that contained those characters would not be considered part of the testfile.
  • Loading branch information
anoadragon453 authored Jun 19, 2019
1 parent 3cd582c commit 24678f5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions run-tests.pl
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ sub usage
# Read in test blacklist rules if set
my %TEST_BLACKLIST;
if ( $BLACKLIST_FILE ) {
open( my $blacklist_data, "<", $BLACKLIST_FILE ) or die "Couldn't open blacklist file for reading: $!\n";
open( my $blacklist_data, "<:encoding(UTF-8)", $BLACKLIST_FILE ) or die "Couldn't open blacklist file for reading: $!\n";
while ( my $test_name = <$blacklist_data> ) {
# Trim whitespace
chomp $test_name;
Expand All @@ -222,7 +222,7 @@ sub usage
# Read in test whitelist rules if set
my %TEST_WHITELIST;
if ( $WHITELIST_FILE ) {
open( my $whitelist_data, "<", $WHITELIST_FILE ) or die "Couldn't open whitelist file for reading: $!\n";
open( my $whitelist_data, "<:encoding(UTF-8)", $WHITELIST_FILE ) or die "Couldn't open whitelist file for reading: $!\n";
while ( my $test_name = <$whitelist_data> ) {
# Trim whitespace
chomp $test_name;
Expand Down

0 comments on commit 24678f5

Please sign in to comment.