Bug #10359

Force UTF-8 locale in automated test suite

Added by anonym 2015-10-12 03:01:00 . Updated 2015-11-03 11:28:52 .

Status:
Resolved
Priority:
Normal
Assignee:
Category:
Test suite
Target version:
Start date:
2015-10-12
Due date:
% Done:

100%

Feature Branch:
test/10359-force-utf-8
Type of work:
Code
Blueprint:

Starter:
Affected tool:
Deliverable for:

Description

In the ‘the Unsafe Browser works in all supported languages’ step we read config/chroot_local-includes/usr/share/tails/browser-localization/descriptions from our Git. It contains some UTF-8 => non-ASCII characters, so if the system locale is non-UTF-8 (e.g. POSIX) then we get this error when we try to operate on it (split() in this case):

Then the Unsafe Browser works in all supported languages                   # features/step_definitions/unsafe_browser.rb:25
  invalid byte sequence in US-ASCII (ArgumentError)
  ./features/step_definitions/unsafe_browser.rb:8:in `split'
[...]


We should force UTF-8, which can be done with:

Encoding.default_external = Encoding::UTF_8
Encoding.default_internal = Encoding::UTF_8

Subtasks


History

#1 Updated by anonym 2015-10-12 03:24:36

  • Status changed from Confirmed to In Progress

Applied in changeset commit:de75bc1604d6478325f69f922a2cd902055771be.

#2 Updated by anonym 2015-10-12 03:25:05

  • Assignee changed from anonym to bertagaz
  • QA Check set to Ready for QA
  • Feature Branch set to test/10359-force-utf-8

This will hopefully fix the issue on tailstester1.

#3 Updated by anonym 2015-10-12 03:41:27

Applied in changeset commit:50c660cb54c8f4fe34ab957154944e7deeed6da3.

#4 Updated by bertagaz 2015-10-16 01:43:14

  • Status changed from In Progress to Fix committed
  • Assignee deleted (bertagaz)
  • % Done changed from 0 to 100
  • QA Check changed from Ready for QA to Pass

I’ve merged this branch after testing it locally.

#5 Updated by anonym 2015-11-03 11:28:52

  • Status changed from Fix committed to Resolved