示例#1
0
 def testGetSplitsSplitApk(self):
     apk = apk_helper.ToSplitHelper(
         'base.apk', ['split1.apk', 'split2.apk', 'split3.apk'])
     device = _MockDeviceUtils()
     with self.assertCalls(
         (mock.call.devil.android.sdk.split_select.SelectSplits(
             device,
             'base.apk', ['split1.apk', 'split2.apk', 'split3.apk'],
             allow_cached_props=False), ['split2.apk'])),\
       apk.GetApkPaths(device) as apk_paths:
         self.assertEquals(apk_paths, ['base.apk', 'split2.apk'])
示例#2
0
 def testToHelperSplitException(self):
     with self.assertRaises(apk_helper.ApkHelperError):
         apk_helper.ToSplitHelper(apk_helper.ToHelper('abc.apk'),
                                  ['a.apk', 'b.apk'])
示例#3
0
 def testToHelperSplitApk(self):
     apk = apk_helper.ToSplitHelper('abc.apk', ['a.apk', 'b.apk'])
     self.assertTrue(isinstance(apk, apk_helper.SplitApkHelper))