Ejemplo n.º 1
0
	def __init__(self, manifestPath):
		assert manifestPath is not None

		XmlPatcher.__init__(self, manifestPath)

		self.androidNs = "http://schemas.android.com/apk/res/android"
		self.androidNsPrefix = 'android'

		self.namespaces[self.androidNsPrefix] = self.androidNs
		self.regNamespace(self.androidNsPrefix, self.androidNs)
Ejemplo n.º 2
0
class TestXmlPatcher(unittest.TestCase):
	def setUp(self):
		self.patcher = XmlPatcher('somePath')

	def test_getNameWithNs(self):
		name = self.patcher.getNameWithNs('OriginalName', 'http://namespace')
		self.assertEqual('{http://namespace}OriginalName', name)
Ejemplo n.º 3
0
	def setUp(self):
		self.patcher = XmlPatcher('somePath')