INNER CODE UNIT · Python
test_ignores_comments
connectbot/connectbot · translations/test_translate.py:256
def test_ignores_comments(self):
root = resources_elem('<!-- comment -->\n<string name="foo">Foo</string>')
idx = build_target_index(root)
assert list(idx.keys()) == ["foo"]
def test_ignores_non_translatable_tags(self):
root = parse(resources_xml('<color name="red">#FF0000</color>'))
idx = build_target_index(root)
assert idx == {}
# ---------------------------------------------------------------------------
# ensure_tools_namespace
# ---------------------------------------------------------------------------
class TestEnsureToolsNamespace:
def test_new_resources_tree_has_tools_namespace(self):
tree = new_resources_tree()