def _GetTestData(cls):
   ids = [cros_patch.MakeChangeId() for _ in xrange(3)]
   changes = [cls._GetCrosInternalPatch(GetTestJson(ids[0]))]
   non_os = [cls._GetCrosPatch(GetTestJson(ids[1]))]
   conflicting = [cls._GetCrosInternalPatch(GetTestJson(ids[2]))]
   conflicting = [cros_patch.PatchException(x)for x in conflicting]
   pool = validation_pool.ValidationPool(
       constants.PUBLIC_OVERLAYS,
       '/fake/pathway', 1,
       'testing', True, True,
       changes=changes, non_os_changes=non_os,
       conflicting_changes=conflicting)
   return pickle.dumps([pool, changes, non_os, conflicting])
Esempio n. 2
0
 def MakeChangeId(self, how_many=1):
     l = [cros_patch.MakeChangeId() for _ in xrange(how_many)]
     if how_many == 1:
         return l[0]
     return l