INNER CODE UNIT · Python

test_ignores_non_translatable_tags

connectbot/connectbot · translations/test_translate.py:261

    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()
        root = tree.getroot()
        assert TOOLS_NS in root.nsmap.values()

    def test_adds_namespace_to_root_without_it(self):
        root = parse("<resources><string name='x'>X</string></resources>")

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…