mirror of
https://github.com/onionshare/onionshare.git
synced 2025-05-03 23:15:18 -04:00
pep8: fix empty line counts
top level: 2, else 1 I also advice to not put "pass" into empty classes, but rather a docstring instead of "pass".
This commit is contained in:
parent
5deb3f9e0f
commit
179eefae29
16 changed files with 74 additions and 15 deletions
|
@ -21,16 +21,19 @@ import locale
|
|||
from onionshare import strings
|
||||
from nose import with_setup
|
||||
|
||||
|
||||
def test_starts_with_empty_strings():
|
||||
"""creates an empty strings dict by default"""
|
||||
assert strings.strings == {}
|
||||
|
||||
|
||||
def test_load_strings_defaults_to_english():
|
||||
"""load_strings() loads English by default"""
|
||||
locale.getdefaultlocale = lambda: ('en_US', 'UTF-8')
|
||||
strings.load_strings()
|
||||
assert strings._('wait_for_hs') == "Waiting for HS to be ready:"
|
||||
|
||||
|
||||
def test_load_strings_loads_other_languages():
|
||||
"""load_strings() loads other languages in different locales"""
|
||||
locale.getdefaultlocale = lambda: ('fr_FR', 'UTF-8')
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue