MCPcopy Index your code
hub / github.com/python/cpython / test_keyed_archive_data

Method test_keyed_archive_data

Lib/test/test_plistlib.py:1163–1191  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1161
1162class TestKeyedArchive(unittest.TestCase):
1163 def test_keyed_archive_data(self):
1164 # This is the structure of a NSKeyedArchive packed plist
1165 data = {
1166 '$version': 100000,
1167 '$objects': [
1168 '$null', {
1169 'pytype': 1,
1170 '$class': UID(2),
1171 'NS.string': 'KeyArchive UID Test'
1172 },
1173 {
1174 '$classname': 'OC_BuiltinPythonUnicode',
1175 '$classes': [
1176 'OC_BuiltinPythonUnicode',
1177 'OC_PythonUnicode',
1178 'NSString',
1179 'NSObject'
1180 ],
1181 '$classhints': [
1182 'OC_PythonString', 'NSString'
1183 ]
1184 }
1185 ],
1186 '$archiver': 'NSKeyedArchiver',
1187 '$top': {
1188 'root': UID(1)
1189 }
1190 }
1191 self.assertEqual(plistlib.loads(TESTDATA["KEYED_ARCHIVE"]), data)
1192
1193
1194class MiscTestCase(unittest.TestCase):

Callers

nothing calls this directly

Calls 3

UIDClass · 0.90
assertEqualMethod · 0.45
loadsMethod · 0.45

Tested by

no test coverage detected