Пример #1
0
 def runCommand(self,
                cfg,
                argSet,
                args,
                profile=False,
                callback=None,
                repos=None):
     if len(args) < 3:
         return explain.docAll(cfg)
     return explain.docObject(cfg, args[2])
Пример #2
0
 def testExplainGroupInfoRecipe(self):
     def mockPageDoc(className, obj):
         self.assertEquals('GroupInfoRecipe', className)
         self.assertFalse('Build Actions' not in obj)
     self.mock(explain, '_pageDoc', mockPageDoc)
     explain.docObject(self.cfg, 'GroupInfoRecipe')
Пример #3
0
 def testCvcExplainInfo(self):
     def mockFormatDoc(className, obj):
         self.assertFalse(not 'r.User' in obj.__doc__)
         self.assertEquals(obj.__module__, 'conary.build.build')
     self.mock(explain, '_formatDoc', mockFormatDoc)
     explain.docObject(self.cfg, 'UserInfoRecipe.User')
Пример #4
0
 def testExplainPkgRecipe(self):
     def mockPageDoc(className, obj):
         self.assertEquals('PackageRecipe', className)
         self.assertFalse('PackageRecipe' not in obj)
     self.mock(explain, '_pageDoc', mockPageDoc)
     explain.docObject(self.cfg, 'PackageRecipe')
Пример #5
0
 def testCvcExplainGroupPolicy(self):
     def mockFormatDoc(className, obj):
         self.assertFalse(not 'r.VersionConflicts' in obj.__doc__)
         self.assertEquals(obj.__module__, 'group_versionconflicts')
     self.mock(explain, '_formatDoc', mockFormatDoc)
     explain.docObject(self.cfg, 'VersionConflicts')
Пример #6
0
 def testCvcExplainGroup(self):
     def mockFormatDoc(className, obj):
         self.assertFalse(not 'r.addCopy' in obj.__doc__)
         self.assertEquals(obj.__module__, 'conary.build.grouprecipe')
     self.mock(explain, '_formatDoc', mockFormatDoc)
     explain.docObject(self.cfg, 'addCopy')
Пример #7
0
 def testCvcExplainPolicy(self):
     def mockFormatDoc(className, obj):
         self.assertFalse(not 'r.Config' in obj.__doc__)
         self.assertEquals(obj.__module__, 'conary.build.packagepolicy')
     self.mock(explain, '_formatDoc', mockFormatDoc)
     explain.docObject(self.cfg, 'Config')
Пример #8
0
 def testExplainRecipe(self):
     def mockFormatDoc(className, obj):
         self.assertFalse(not 'r.Move' in obj.__doc__)
         self.assertEquals(obj.__module__, 'conary.build.build')
     self.mock(explain, '_formatDoc', mockFormatDoc)
     explain.docObject(self.cfg, 'Move')
Пример #9
0
 def runCommand(self, cfg, argSet, args, profile = False,
                callback = None, repos=None):
     if len(args) < 3:
         return explain.docAll(cfg)
     return explain.docObject(cfg, args[2])