Beispiel #1
0
    def testInsertCategoryName1WeightLong(self):
        aCategory = category()
        result = aCategory.insertCategory('A', ((2**28) - 1))
        self.assertTrue(result)

        # Eliminando la categoria
        aCategory.deleteCategory('A')
Beispiel #2
0
    def testInsertCategoryExists(self):
        aCategory = category()
        result = aCategory.insertCategory('Kxtygzry1', 21)
        self.assertTrue(result)

        # Eliminando la categoria
        aCategory.deleteCategory('Kxtygzry1')
Beispiel #3
0
    def testInsertCategoryName100Weight0(self):
        aCategory = category()
        result = aCategory.insertCategory('A' * 100, 0)
        self.assertTrue(result)

        # Eliminando la categoria
        aCategory.deleteCategory('A' * 100)
Beispiel #4
0
 def testInsertCategoryWeight0(self):
     aCategory = category()
     result    = aCategory.insertCategory('Kxtygzrda',0)
     self.assertTrue(result)
      
     # Eliminando la categoria
     aCategory.deleteCategory('Kxtygzrda')
Beispiel #5
0
    def testCicloIndirecto(self):
        # Insertamos Producto
        aBacklog = backlog()
        aBacklog.insertBacklog('Podn fjdd.', 'ODJdbeidbww', 1)
        searchBacklog = aBacklog.findName('Podn fjdd.')
        idFound0 = searchBacklog[0].BL_idBacklog

        # Insertamos la accion
        aAcc = accions()
        aAcc.insertAccion('cinrohbwidia', idFound0)
        search = aAcc.searchAccion('cinrohbwidia', idFound0)
        idFound = search[0].AC_idAccion

        # Insertamos la historia
        aHist = userHistory()
        aHist.insertUserHistory('BIEEIEB1', 0, 1, idFound, idFound0, 1, True,
                                TODAY)
        searchHist = aHist.searchUserHistory('BIEEIEB1', idFound0)
        idFound1 = searchHist[0].UH_idUserHistory

        # Insertamos la categoria
        aCategory = category()
        aCategory.insertCategory('wofhweoifh', 1)

        # Insertamos la tarea 1
        aTarea = task()
        aTarea.insertTask('dwidjw', 1, 1, idFound1, True, TODAY)
        searchTask1 = aTarea.searchTask('dwidjw')
        idprimera = searchTask1[0].HW_idTask

        # Insertamos la tarea 2
        bTarea = task()
        bTarea.insertTask('dfghj', 2, 2, idFound1, True, TODAY)
        searchTask2 = bTarea.searchTask('dfghj')
        idsegunda = searchTask2[0].HW_idTask

        # Insertamos la tarea 3
        cTarea = task()
        cTarea.insertTask('dfghj2', 3, 3, idFound1, True, TODAY)
        searchTask3 = cTarea.searchTask('dfghj2')
        idtercera = searchTask3[0].HW_idTask

        #Insertamos la precedencia
        aPrecedence = precedence()
        aPrecedence.insertPrecedence(idprimera, idsegunda, idFound0)
        aPrecedence.insertPrecedence(idsegunda, idtercera, idFound0)
        self.assertEqual(
            (aPrecedence.insertPrecedence(idtercera, idprimera, idFound0)),
            None)

        # Eliminamos la precedencia, tarea, categoria, historia, accion y producto
        aPrecedence.deletePrecedence(idprimera, idsegunda)
        aPrecedence.deletePrecedence(idsegunda, idtercera)
        aTarea.deleteTask('dwidjw')
        bTarea.deleteTask('dfghj')
        bTarea.deleteTask('dfghj2')
        aCategory.deleteCategory('wofhweoifh')
        aHist.deleteUserHistory(idFound1)
        aAcc.deleteAccion('cinrohbwidia', idFound0)
        aBacklog.deleteProduct('Podn fjdd.')
Beispiel #6
0
    def testInsertCategoryName100Weight0(self):
        aCategory = category()
        result    = aCategory.insertCategory('A'*100,0)
        self.assertTrue(result)
 
        # Eliminando la categoria
        aCategory.deleteCategory('A'*100)
Beispiel #7
0
 def testDeleteCategoryNameStringArray(self):
     aCategory = category()
     aCategory.insertCategory('[]',1)
      
     # Eliminando la categoria
     result = aCategory.deleteCategory('[]')
     self.assertTrue(result)
Beispiel #8
0
 def testDeleteCategoryNameDictionary(self):
     aCategory = category()
     aCategory.insertCategory({},1)
      
     # Eliminando la categoria
     result = aCategory.deleteCategory({})
     self.assertFalse(result)
Beispiel #9
0
 def testDeleteCategoryNameArray(self):
     aCategory = category()
     aCategory.insertCategory([],1)
      
     # Eliminando la categoria
     result = aCategory.deleteCategory([])
     self.assertFalse(result)
Beispiel #10
0
 def testDeleteCategoryNameEnie(self):
     aCategory = category()
     aCategory.insertCategory('ñ',1)
      
     # Eliminando la categoria
     result = aCategory.deleteCategory('ñ')
     self.assertTrue(result)
Beispiel #11
0
    def testInsertCategoryName1WeightLong(self):
        aCategory = category()
        result    = aCategory.insertCategory('A',((2**28)-1))
        self.assertTrue(result)
 
        # Eliminando la categoria
        aCategory.deleteCategory('A')
Beispiel #12
0
 def testDeleteCategoryNameNumber(self):
     aCategory = category()
     aCategory.insertCategory(88,1)
      
     # Eliminando la categoria
     result = aCategory.deleteCategory(88)
     self.assertFalse(result)
Beispiel #13
0
 def testDeleteCategoryName101(self):
     aCategory = category()
     aCategory.insertCategory('C'*101,1)
      
     # Eliminando la categoria
     result = aCategory.deleteCategory('C'*101)
     self.assertFalse(result)
Beispiel #14
0
 def testDeleteCategoryNameLong(self):
     aCategory = category()
     aCategory.insertCategory('C'*((2**28)-1),1)
      
     # Eliminando la categoria
     result = aCategory.deleteCategory('C'*((2**28)-1))
     self.assertFalse(result)
Beispiel #15
0
 def testDeleteCategoryExist(self):
     aCategory = category()
     aCategory.insertCategory('Kxtygzrda',1)
      
     # Eliminando la categoria
     result = aCategory.deleteCategory('Kxtygzrda')
     self.assertTrue(result)
Beispiel #16
0
 def testDeleteCategoryName50(self):
     aCategory = category()
     aCategory.insertCategory('C'*50,1)
      
     # Eliminando la categoria
     result = aCategory.deleteCategory('C'*50)
     self.assertTrue(result)
Beispiel #17
0
    def testInsertCategory100Exists(self):
        aCategory = category()
        result = aCategory.insertCategory('A' * 100, 2)
        self.assertTrue(result)

        # Eliminando la categoria
        aCategory.deleteCategory('A' * 100)
Beispiel #18
0
    def testDeleteCategoryNameNumber(self):
        aCategory = category()
        aCategory.insertCategory(88, 1)

        # Eliminando la categoria
        result = aCategory.deleteCategory(88)
        self.assertFalse(result)
Beispiel #19
0
    def testDeleteCategoryNameArray(self):
        aCategory = category()
        aCategory.insertCategory([], 1)

        # Eliminando la categoria
        result = aCategory.deleteCategory([])
        self.assertFalse(result)
Beispiel #20
0
    def testDeleteCategoryNameLong(self):
        aCategory = category()
        aCategory.insertCategory('C' * ((2**28) - 1), 1)

        # Eliminando la categoria
        result = aCategory.deleteCategory('C' * ((2**28) - 1))
        self.assertFalse(result)
Beispiel #21
0
    def testDeleteCategoryNameEnie(self):
        aCategory = category()
        aCategory.insertCategory('ñ', 1)

        # Eliminando la categoria
        result = aCategory.deleteCategory('ñ')
        self.assertTrue(result)
Beispiel #22
0
    def testDeleteCategoryName101(self):
        aCategory = category()
        aCategory.insertCategory('C' * 101, 1)

        # Eliminando la categoria
        result = aCategory.deleteCategory('C' * 101)
        self.assertFalse(result)
Beispiel #23
0
    def testDeleteCategoryName50(self):
        aCategory = category()
        aCategory.insertCategory('C' * 50, 1)

        # Eliminando la categoria
        result = aCategory.deleteCategory('C' * 50)
        self.assertTrue(result)
Beispiel #24
0
    def testDeleteCategoryExist(self):
        aCategory = category()
        aCategory.insertCategory('Kxtygzrda', 1)

        # Eliminando la categoria
        result = aCategory.deleteCategory('Kxtygzrda')
        self.assertTrue(result)
Beispiel #25
0
    def testDeleteCategoryNameStringArray(self):
        aCategory = category()
        aCategory.insertCategory('[]', 1)

        # Eliminando la categoria
        result = aCategory.deleteCategory('[]')
        self.assertTrue(result)
Beispiel #26
0
    def testDeleteCategoryNameDictionary(self):
        aCategory = category()
        aCategory.insertCategory({}, 1)

        # Eliminando la categoria
        result = aCategory.deleteCategory({})
        self.assertFalse(result)
Beispiel #27
0
    def testInsertCategoryWeight0(self):
        aCategory = category()
        result = aCategory.insertCategory('Kxtygzrda', 0)
        self.assertTrue(result)

        # Eliminando la categoria
        aCategory.deleteCategory('Kxtygzrda')
Beispiel #28
0
    def testInsertCategory100Exists(self):
        aCategory = category()
        result    = aCategory.insertCategory('A'*100,2)
        self.assertTrue(result)
 
        # Eliminando la categoria
        aCategory.deleteCategory('A'*100)
Beispiel #29
0
    def testInsertCategoryExists(self):
        aCategory = category()
        result    = aCategory.insertCategory('Kxtygzry1',21)
        self.assertTrue(result)
 
        # Eliminando la categoria
        aCategory.deleteCategory('Kxtygzry1')
Beispiel #30
0
 def testUpdateCategoryName100Newname0Weight0(self):
     aCategory = category()
     aCategory.insertCategory('C'*100,1)
     result    = aCategory.updateCategory('C'*100, '', 0)
     self.assertFalse(result)
      
     # Eliminando la categoria
     aCategory.deleteCategory('C'*100)
Beispiel #31
0
 def testUpdateCategoryWeightLong(self):
     aCategory = category()
     aCategory.insertCategory('Kxtygzrda',1)
     result    = aCategory.updateCategory('Kxtygzrda', 'Nxyvz kxtygzrya', ((2**28)-1))
     self.assertTrue(result)
      
     # Eliminando la categoria
     aCategory.deleteCategory('Nxyvz kxtygzrya')
Beispiel #32
0
 def testUpdateCategoryNewnameLong(self):
     aCategory = category()
     aCategory.insertCategory('Kxtygzrda',1)
     result    = aCategory.updateCategory('Kxtygzrda', 'N'*((2**28)-1), 2)
     self.assertFalse(result)
      
     # Eliminando la categoria
     aCategory.deleteCategory('Kxtygzrda')
Beispiel #33
0
 def testUpdateCategoryNewname101(self):
     aCategory = category()
     aCategory.insertCategory('Kxtygzrda',1)
     result    = aCategory.updateCategory('C', 'N'*101, 2)
     self.assertFalse(result)
      
     # Eliminando la categoria
     aCategory.deleteCategory('Kxtygzrda')
Beispiel #34
0
 def testUpdateCategoryNameNewname100(self):
     aCategory = category()
     aCategory.insertCategory('Kxtygzrda',1)
     result    = aCategory.updateCategory('Kxtygzrda', 'N'*100, 2)
     self.assertTrue(result)
      
     # Eliminando la categoria
     aCategory.deleteCategory('N'*100)
Beispiel #35
0
 def testUpdateCategoryName100Newname(self):
     aCategory = category()
     aCategory.insertCategory('C'*100,1)
     result    = aCategory.updateCategory('C'*100, 'Nxyvz kxtygzrya', 2)
     self.assertTrue(result)
      
     # Eliminando la categoria
     aCategory.deleteCategory('Nxyvz kxtygzrya')
Beispiel #36
0
    def testSearchIdCategoryDictionary(self):
        aCategory = category()
        aCategory.insertCategory('Kxtygzrda', 1)
        result = aCategory.searchIdCategory({})
        self.assertFalse(result)

        # Eliminando la categoria
        aCategory.deleteCategory('Kxtygzrda')
Beispiel #37
0
 def testSearchIdCategoryNotExist(self):
     aCategory = category()
     aCategory.insertCategory('Kxtygzrda',1)
     result    = aCategory.searchIdCategory(99)
     self.assertFalse(result)
      
     # Eliminando la categoria
     aCategory.deleteCategory('Kxtygzrda')    
Beispiel #38
0
 def testUpdateCategoryNameNewnameNumberWeight(self):
     aCategory = category()
     aCategory.insertCategory('Kxtygzrda',1)
     result    = aCategory.updateCategory('Kxtygzrda', 21, 3)
     self.assertFalse(result)
      
     # Eliminando la categoria
     aCategory.deleteCategory('Kxtygzrda')
Beispiel #39
0
 def testUpdateCategoryName100NewnameLongWeightLong1(self):
     aCategory = category()
     aCategory.insertCategory('C'*100,1)
     result    = aCategory.updateCategory('C', 'N'*((2**28)-1), 1)
     self.assertFalse(result)
      
     # Eliminando la categoria
     aCategory.deleteCategory('C'*100)        
Beispiel #40
0
    def testInsertCategoryEquals(self):
        aCategory = category()
        result = aCategory.insertCategory('Kxtygzrda', 2)
        result1 = aCategory.insertCategory('Kxtygzrda', 3)
        self.assertFalse(result1)

        # Eliminando la categoria
        aCategory.deleteCategory('Kxtygzrda')
Beispiel #41
0
 def testUpdateCategoryName1Newname1WeightLong(self):
     aCategory = category()
     aCategory.insertCategory('C',1)
     result    = aCategory.updateCategory('C', 'N', (2**28)-1)
     self.assertTrue(result)
      
     # Eliminando la categoria
     aCategory.deleteCategory('N')
Beispiel #42
0
    def testInsertCategory100Equals(self):
        aCategory = category()
        result = aCategory.insertCategory('C' * 100, 2)
        result1 = aCategory.insertCategory('C' * 100, 3)
        self.assertFalse(result1)

        # Eliminando la categoria
        aCategory.deleteCategory('C' * 100)
Beispiel #43
0
 def testUpdateCategoryNameNewnameEnieWeight(self):
     aCategory = category()
     aCategory.insertCategory('Kxtygzrda',1)
     result    = aCategory.updateCategory('Kxtygzrda', 'ñ', 3)
     self.assertTrue(result)
      
     # Eliminando la categoria
     aCategory.deleteCategory('ñ')
Beispiel #44
0
 def testSearchIdCategoryDictionary(self):
     aCategory = category()
     aCategory.insertCategory('Kxtygzrda',1)
     result    = aCategory.searchIdCategory({})
     self.assertFalse(result)
      
     # Eliminando la categoria
     aCategory.deleteCategory('Kxtygzrda')
Beispiel #45
0
 def testUpdateCategoryNameNewnameWeightNegativeNumber(self):
     aCategory = category()
     aCategory.insertCategory('Kxtygzrda',1)
     result    = aCategory.updateCategory('Kxtygzrda', 'Nxyvz kxtygzrya', -3)
     self.assertFalse(result)
      
     # Eliminando la categoria
     aCategory.deleteCategory('Kxtygzrda')
Beispiel #46
0
    def testSearchIdCategoryNotExist(self):
        aCategory = category()
        aCategory.insertCategory('Kxtygzrda', 1)
        result = aCategory.searchIdCategory(99)
        self.assertFalse(result)

        # Eliminando la categoria
        aCategory.deleteCategory('Kxtygzrda')
Beispiel #47
0
 def testSearchIdCategoryLong(self):
     aCategory = category()
     aCategory.insertCategory('Kxtygzrda',1)
     result    = aCategory.searchIdCategory((2**28)-1)
     self.assertFalse(result)
      
     # Eliminando la categoria
     aCategory.deleteCategory('Kxtygzrda')
Beispiel #48
0
    def testSearchIdCategoryLong(self):
        aCategory = category()
        aCategory.insertCategory('Kxtygzrda', 1)
        result = aCategory.searchIdCategory((2**28) - 1)
        self.assertFalse(result)

        # Eliminando la categoria
        aCategory.deleteCategory('Kxtygzrda')
Beispiel #49
0
    def testUpdateCategoryNameNewnameNumberWeight(self):
        aCategory = category()
        aCategory.insertCategory('Kxtygzrda', 1)
        result = aCategory.updateCategory('Kxtygzrda', 21, 3)
        self.assertFalse(result)

        # Eliminando la categoria
        aCategory.deleteCategory('Kxtygzrda')
Beispiel #50
0
    def testUpdateCategoryNameNewnameWeightNegativeNumber(self):
        aCategory = category()
        aCategory.insertCategory('Kxtygzrda', 1)
        result = aCategory.updateCategory('Kxtygzrda', 'Nxyvz kxtygzrya', -3)
        self.assertFalse(result)

        # Eliminando la categoria
        aCategory.deleteCategory('Kxtygzrda')
Beispiel #51
0
    def testUpdateCategoryName100NewnameLongWeightLong1(self):
        aCategory = category()
        aCategory.insertCategory('C' * 100, 1)
        result = aCategory.updateCategory('C', 'N' * ((2**28) - 1), 1)
        self.assertFalse(result)

        # Eliminando la categoria
        aCategory.deleteCategory('C' * 100)
Beispiel #52
0
    def testUpdateCategoryNameNewnameEnieWeight(self):
        aCategory = category()
        aCategory.insertCategory('Kxtygzrda', 1)
        result = aCategory.updateCategory('Kxtygzrda', 'ñ', 3)
        self.assertTrue(result)

        # Eliminando la categoria
        aCategory.deleteCategory('ñ')
Beispiel #53
0
 def testInsertCategoryEquals(self):
     aCategory = category()
     result    = aCategory.insertCategory('Kxtygzrda',2)
     result1   = aCategory.insertCategory('Kxtygzrda',3)
     self.assertFalse(result1)
      
     # Eliminando la categoria
     aCategory.deleteCategory('Kxtygzrda')
Beispiel #54
0
    def testUpdateCategoryName1Newname1WeightLong(self):
        aCategory = category()
        aCategory.insertCategory('C', 1)
        result = aCategory.updateCategory('C', 'N', (2**28) - 1)
        self.assertTrue(result)

        # Eliminando la categoria
        aCategory.deleteCategory('N')
Beispiel #55
0
    def testUpdateCategoryWeight0(self):
        aCategory = category()
        aCategory.insertCategory('Kxtygzrda', 1)
        result = aCategory.updateCategory('Kxtygzrda', 'Nxyvz kxtygzrya', 0)
        self.assertTrue(result)

        # Eliminando la categoria
        aCategory.deleteCategory('Nxyvz kxtygzrya')
Beispiel #56
0
    def testUpdateCategoryName100Newname0Weight0(self):
        aCategory = category()
        aCategory.insertCategory('C' * 100, 1)
        result = aCategory.updateCategory('C' * 100, '', 0)
        self.assertFalse(result)

        # Eliminando la categoria
        aCategory.deleteCategory('C' * 100)
Beispiel #57
0
    def testUpdateCategoryNewname101(self):
        aCategory = category()
        aCategory.insertCategory('Kxtygzrda', 1)
        result = aCategory.updateCategory('C', 'N' * 101, 2)
        self.assertFalse(result)

        # Eliminando la categoria
        aCategory.deleteCategory('Kxtygzrda')
Beispiel #58
0
    def testUpdateCategoryNewnameLong(self):
        aCategory = category()
        aCategory.insertCategory('Kxtygzrda', 1)
        result = aCategory.updateCategory('Kxtygzrda', 'N' * ((2**28) - 1), 2)
        self.assertFalse(result)

        # Eliminando la categoria
        aCategory.deleteCategory('Kxtygzrda')
Beispiel #59
0
 def testInsertCategory100Equals(self):
     aCategory = category()
     result    = aCategory.insertCategory('C'*100,2)
     result1   = aCategory.insertCategory('C'*100,3)
     self.assertFalse(result1)
      
     # Eliminando la categoria
     aCategory.deleteCategory('C'*100)
Beispiel #60
0
    def testUpdateCategoryNameNewname100(self):
        aCategory = category()
        aCategory.insertCategory('Kxtygzrda', 1)
        result = aCategory.updateCategory('Kxtygzrda', 'N' * 100, 2)
        self.assertTrue(result)

        # Eliminando la categoria
        aCategory.deleteCategory('N' * 100)