Skip to content

Commit 4795c86

Browse files
committed
Test that update actually accepts those boolean parameters
1 parent fbc1648 commit 4795c86

1 file changed

Lines changed: 10 additions & 1 deletion

File tree

tests/messages/test_frontend.py

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
from babel import __version__ as VERSION
2828
from babel.dates import format_datetime
2929
from babel.messages import frontend, Catalog
30-
from babel.messages.frontend import CommandLineInterface, extract_messages
30+
from babel.messages.frontend import CommandLineInterface, extract_messages, update_catalog
3131
from babel.util import LOCALTZ
3232
from babel.messages.pofile import read_po, write_po
3333
from babel._compat import StringIO
@@ -1291,3 +1291,12 @@ def test_extract_keyword_args_384(split):
12911291
'ungettext',
12921292
'ungettext_lazy',
12931293
))
1294+
1295+
1296+
def test_update_catalog_boolean_args():
1297+
cmdinst = configure_cli_command("update --no-wrap -N --ignore-obsolete --previous -i foo -o foo -l en")
1298+
assert isinstance(cmdinst, update_catalog)
1299+
assert cmdinst.no_wrap is True
1300+
assert cmdinst.no_fuzzy_matching is True
1301+
assert cmdinst.ignore_obsolete is True
1302+
assert cmdinst.previous is False # Mutually exclusive with no_fuzzy_matching

0 commit comments

Comments
 (0)