Exemplo n.º 1
0
def runTestSuite():
    """
    Transfer function for setup.py script ro-manager-test
    """
    base = os.path.dirname(__file__)
    #print "Run test suite assuming base path "+base
    sys.path.insert(0, os.path.normpath(base+"/..") )
    sys.path.insert(0, os.path.normpath(base+"/../..") )
    sys.path.insert(0, os.path.normpath(base+"/../../iaeval/test") )
    sys.path.insert(0, os.path.normpath(base+"/../../sync/test") )
    #print "Path: "+repr(sys.path)
    TestUtils.runTests("TestAll", getTestSuite, sys.argv)
    return 0
Exemplo n.º 2
0
            "component"   return suite of component tests
            "integration" return suite of integration tests
            "all"         return suite of unit and component tests
            "pending"     return suite of pending tests
            name          a single named test to be run
    """
    testdict = {
        "unit": 
            [ "testUnits"
            , "testOrigConfig"
            , "testMakeConfig"
            , "testCopyConfig"
            , "testSetConfig"
            ],
        "component":
            [ "testComponents"
            ],
        "integration":
            [ "testIntegration"
            ],
        "pending":
            [ "testPending"
            ]
        }
    return TestUtils.getTestSuite(TestWbConfigEdit, testdict, select=select)

# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestWbConfigEdit.log", getTestSuite, sys.argv)

Exemplo n.º 3
0
            , "testUserACreateHTTPCollabDeleteHTTP"       
            # Test RG Leader's access permissions on files in User A's Private area     
            , "testRGLeaderCreateCIFSInUserA"
            , "testUserACreateCIFSRGLeaderReadCIFS"
            , "testUserACreateCIFSRGLeaderUpdateCIFS"
            , "testUserACreateCIFSRGLeaderDeleteCIFS"
            , "testRGLeaderCreateHTTPInUserA"
            , "testUserACreateHTTPRGLeaderReadHTTP"
            , "testUserACreateHTTPRGLeaderUpdateHTTP"
            , "testUserACreateHTTPRGLeaderDeleteHTTP"
            ],
        "component":
            [ "testComponents"
            ],
        "integration":
            [ "testIntegration"
            ],
        "pending":
            [ "testPending"
            ]
        }
    return TestUtils.getTestSuite(TestFileCommonArea, testdict, select=select)

# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestFileCommonArea.log", getTestSuite, sys.argv)

# End.


Exemplo n.º 4
0
    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": [
            "testUnits",
            "testUnWrap1",
            "testUnWrap2",
            "testUnWrap3",
            "testUnWrap4",
            "testUnWrap5",
            "testFlatten1",
            "testFlatten2",
        ],
        "component": ["testComponents"],
        "integration": ["testIntegration"],
        "pending": ["testPending"],
    }
    return TestUtils.getTestSuite(TestEventEnvelope, testdict, select=select)


# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestEventEnvelope.log", getTestSuite, sys.argv)

# End.
Exemplo n.º 5
0
            name        a single named test to be run
    """
    testdict = {
        "unit":
            [ "testUnits"
            , "testNull"
            , "testLink"
            , "testLinkType"
            , "testLinkCreated"
            , "testLinkRdfType"
            , "testLinkUnknownUri"
            , "testLinkWithGraph"
            , "testLinkWithNotExistentGraph"
            ],
        "component":
            [ "testComponents"
            ],
        "integration":
            [ "testIntegration"
            ],
        "pending":
            [ "testPending"
            ]
        }
    return TestUtils.getTestSuite(TestLinks, testdict, select=select)

if __name__ == "__main__":
    TestUtils.runTests("TestLinks.log", getTestSuite, sys.argv)

# End.
Exemplo n.º 6
0
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": 
            [ "testEventFromString"
            , "testReadLogFile"
            , "testReadLogFile2"
            , "testLineReader"
            ],
        "component":
            [ "testDummy"
            ],
        "integration":
            [ "testDummy"
            ],
        "pending":
            [ "testDummy"
            , "testReadLogFiles"
            , "ReadZipFileSendEvents"
            , "ReadZipFilesSendEvents"
            ]
        }
    return TestUtils.getTestSuite(TestReadEventLogs, testdict, select=select)

# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestReadEventLogs.log", getTestSuite, sys.argv)
Exemplo n.º 7
0
    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": 
            [ "testUnits"
            , "testMakeDeferred"
            ],
        "component":
            [ "testComponents"
            ],
        "integration":
            [ "testIntegration"
            ],
        "pending":
            [ "testPending"
            ]
        }
    return TestUtils.getTestSuite(TestSyncDeferred, testdict, select=select)

# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestSyncDeferred.log", getTestSuite, sys.argv)

# End.
            , "testSubscriptionForwarding1"
            , "testSubscriptionForwarding2"
            , "testSubscriptionForwarding3"
            , "testSubscriptionForwarding4"
            , "testSubscriptionForwarding5"
            , "testSubscriptionForwarding6"
            , "testSubscriptionForwarding7"
            , "testSubscriptionForwarding8"
            , "testBlockingEventDelivery"
            , "testInterleavedEventDelivery"
            ],
        "component":
            [ "testComponents"
            ],
        "integration":
            [ "testIntegration"
            ],
        "pending":
            [ "testPending"
            , "testWatch"
            ]
        }
    return TestUtils.getTestSuite(TestEventRouterThreaded, testdict, select=select)

# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestEventRouterThreaded.log", getTestSuite, sys.argv)

# End.

Exemplo n.º 9
0
def getTestSuite(select="unit"):
    """
    Get test suite

    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": ["testUnits"],
        "component": ["testComponents"],
        "integration": [
            "testIntegration", "testTestEventHTTPClientIntro",
            "testSubscriptionForwarding1", "testSubscriptionForwarding2",
            "testSubscriptionForwarding3", "testSubscriptionForwarding4",
            "testTestEventHTTPClientDone"
        ],
        "pending": ["testPending"]
    }
    return TestUtils.getTestSuite(TestEventHTTPClient, testdict, select=select)


# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestEventHTTPClient.log", getTestSuite, sys.argv)

# End.
Exemplo n.º 10
0
    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": 
            [ "testUnits"
            , "testCase"
            ],
        "component":
            [ "testComponents"
            ],
        "integration":
            [ "testIntegration"
            ],
        "pending":
            [ "testPending"
            ]
        }
    return TestUtils.getTestSuite(TestExample, testdict, select=select)

# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestExample", getTestSuite, sys.argv)

# End.
Exemplo n.º 11
0

def getTestSuite(select="unit"):
    """
    Get test suite

    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": [
            "testUnits", "testUnWrap1", "testUnWrap2", "testUnWrap3",
            "testUnWrap4", "testUnWrap5", "testFlatten1", "testFlatten2"
        ],
        "component": ["testComponents"],
        "integration": ["testIntegration"],
        "pending": ["testPending"]
    }
    return TestUtils.getTestSuite(TestEventEnvelope, testdict, select=select)


# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestEventEnvelope.log", getTestSuite, sys.argv)

# End.
Exemplo n.º 12
0
    def testAskQueries(self):
        sparqlquery = """ASK { ?s ?p ?o }"""
        pattern = re.compile("[ \n]+")
        responsedata = self.doQueryGET(sparqlquery)
        responsedata = pattern.sub("", responsedata)
        self.assertEqual(responsedata, """{"head":{},"boolean":true}""")


def getTestSuite(select="unit"):
    """
    Get test suite

    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": ["testAskQueries"],
    }
    return TestUtils.getTestSuite(TestSimplePatterns, testdict, select=select)


if __name__ == "__main__":
    TestUtils.runTests("TestSimplePatterns.log", getTestSuite, sys.argv)

# End.
Exemplo n.º 13
0
Created on Sep 13, 2012

@author: zhaoj
'''
import os, os.path
import sys
import unittest
import logging

# Add main library directory to python path
sys.path.append("../../..")
sys.path.append("..")

import TestHelloAnyone
import TestHelloAnyoneWfprov
import TestHelloAnyoneHandmade


def getTestSuite(select="unit"):
    suite = unittest.TestSuite()
    #suite.addTest(TestHelloAnyone.getTestSuite(select=select))
    suite.addTest(TestHelloAnyoneWfprov.getTestSuite(select=select))
    #suite.addTest(TestHelloAnyoneHandmade.getTestSuite(select=select))
    return suite


from MiscLib import TestUtils

if __name__ == "__main__":
    TestUtils.runTests("AllSingleTests.log", getTestSuite, sys.argv)
from MiscLib import TestUtils


def getTestSuite(select="unit"):
    """
    Get test suite

    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": ["testUnits", "testNull", "testServiceDocumentAccess"],
        "component": ["testComponents"],
        "integration": ["testIntegration"],
        "pending": []
    }
    return TestUtils.getTestSuite(TestDatasetSubmission,
                                  testdict,
                                  select=select)


# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestDatasetSubmission", getTestSuite, sys.argv)

# End.
Exemplo n.º 15
0
            "testMakeEnvelopeData2", "testMakeEnvSubscribeData1",
            "testMakeEnvSubscribeData2", "testMakeEnvSubscribeData3",
            "testMakeEnvSubscribeData4", "testMakeEnvUnsubscribeData",
            "testMakeClosedownData", "testMakeIdleData",
            "testParseEnvelopeData1", "testParseEnvelopeData2",
            "testParseEnvelopeData3", "testParseEnvelopeData4",
            "testParseEnvSubscribeData1", "testParseEnvSubscribeData2",
            "testParseEnvSubscribeData3", "testParseEnvUnsubscribeData1",
            "testParseEnvUnsubscribeData2", "testParseEnvUnsubscribeData3",
            "testParseEnvUnsubscribeData4", "testParseEnvUnsubscribeData5",
            "testParseMessageData1", "testParseMessageData2",
            "testParseMessageData3", "testParseMessageData4",
            "testParseMessageData5", "testParseMessageData6",
            "testParseMessageData7", "testParseMessageData8",
            "testParseMessageData9", "testParseMessageData10",
            "testParseMessageData11", "testParseMessageData12",
            "testEventEnvelope2"
        ],
        "component": ["testComponents"],
        "integration": ["testIntegration"],
        "zzpending": ["testPending"]
    }
    return TestUtils.getTestSuite(TestEventSerializer, testdict, select=select)


# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestEventSerializer.log", getTestSuite, sys.argv)

# End.
Exemplo n.º 16
0
            "component"   return suite of component tests
            "integration" return suite of integration tests
            "all"         return suite of unit and component tests
            "pending"     return suite of pending tests
            name          a single named test to be run
    """
    testdict = {
        "unit": 
            [ "testUnits"
            ],
        "component":
            [ "testComponents"
            ],
        "integration":
            [ "testIntegration"
            , "testGetHomepage"
            , "testGetStatus"
            , "testGetConfig"
            , "testCommand"
            ],
        "pending":
            [ "testPending"
            ]
        }
    return TestUtils.getTestSuite(TestWbAccess, testdict, select=select)

# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestWbAccess.log", getTestSuite, sys.argv)

    """
    Get test suite

    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": 
            [ "testLoad"
            , "testRun"
            ],
        "component":
            [ "testDummy"
            ],
        "integration":
            [ "testDummy"
            ],
        "pending":
            [ "testDummy"
            ]
        }
    return TestUtils.getTestSuite(TestScheduleProcessor, testdict, select=select)

# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestScheduleProcessor.log", getTestSuite, sys.argv)
Exemplo n.º 18
0
            "all"       return suite of udirName, baseDir,nit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit":
            [ #"testUnits"
              "testSubmitDatasetHandlerHTMLResponse"
             ,"testSubmitDatasetHandlerDatasetCreation"
             ,"testSubmitDatasetHandlerDatasetDeletion"
             ,"testSubmitDatasetHandlerDirectorySubmission"
             ,"testSubmitDatasetHandlerEmptyDirectorySubmission"
             ,"testSubmitDatasetHandlerUpdateMetadataBeforeSubmission"
             ,"testUpdateLocalManifestAndDatasetSubmission"
            ],
        "component":
            [ #"testComponents"
            ],
        "integration":
            [ #"testIntegration"
            ],
        "pending":
            [ #"testPending"
            ]
        }
    return TestUtils.getTestSuite(TestSubmitDatasetHandler, testdict, select=select)

if __name__ == "__main__":
    TestConfig.setDatasetsBaseDir(".")
    TestUtils.runTests("TestSubmitDatasetHandler.log", getTestSuite, sys.argv)
Exemplo n.º 19
0
def getTestSuite(select="unit"):
    """
    Get test suite

    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": 
            [ "testDataset"
            ],
        "component":
            [ "testDummy"
            ],
        "integration":
            [ "testDummy"
            ],
        "pending":
            [ "testDummy"
            ]
        }
    return TestUtils.getTestSuite(TestDataset, testdict, select=select)

# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestDataset.log", getTestSuite, sys.argv)
    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": ["testUnits", "testNull"],
        "component": [
            "testComponents", "testSharedUserHTTP",
            "testSharedUserCIFSRGLeader", "testSharedUserCIFSCollab"
        ],
        "integration": ["testIntegration"],
        "pending": [
            "testPending", "testReadMeSSH", "testReadMeDAVfs",
            "testCreateFileDAVfs", "testUpdateFileDAVfs",
            "testDeleteFileDAVfs", "testDeleteFileCIFS", "testDeleteFileHTTP"
        ]
    }
    return TestUtils.getTestSuite(TestFileHTTPwriteCIFSread,
                                  testdict,
                                  select=select)


# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestFileHTTPwriteCIFSread", getTestSuite, sys.argv)

# End.
Exemplo n.º 21
0
    """
    testdict = {
        "unit":
            [ "testUnits"
            , "testNull"
            , "testAnnotate"
            , "testAnnotateType"
            , "testAnnotateKeywords"
            , "testAnnotateDescription"
            , "testAnnotateCreated"
            , "testAnnotateTypeUri"
            , "testAnnotateMultiple"
            , "testAnnotationDisplay"
            ],
        "component":
            [ "testComponents"
            ],
        "integration":
            [ "testIntegration"
            ],
        "pending":
            [ "testPending"
            ]
        }
    return TestUtils.getTestSuite(TestAnnotations, testdict, select=select)

if __name__ == "__main__":
    TestUtils.runTests("TestAnnotations.log", getTestSuite, sys.argv)

# End.
    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": [
            "testUnits", "testShutdown", "testSubscriptionRouteTable",
            "testSubscriptionForwarding1", "testSubscriptionForwarding2",
            "testSubscriptionForwarding3", "testSubscriptionForwarding4",
            "testSubscriptionForwarding5", "testSubscriptionForwarding6",
            "testSubscriptionForwarding7", "testSubscriptionForwarding8",
            "testBlockingEventDelivery", "testInterleavedEventDelivery"
        ],
        "component": ["testComponents"],
        "integration": ["testIntegration"],
        "pending": ["testPending", "testWatch"]
    }
    return TestUtils.getTestSuite(TestEventRouterThreaded,
                                  testdict,
                                  select=select)


# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestEventRouterThreaded.log", getTestSuite, sys.argv)

# End.
Exemplo n.º 23
0
import TestTestUtils
import TestFunctions
import TestCombinators
import TestDomHelpers
import TestScanFiles
import TestScanDirectories
import TestNetUtils
import TestSuperGlobal


# Code to run unit tests from all library test modules
def getTestSuite(select="unit"):
    suite = unittest.TestSuite()
    suite.addTest(TestTestUtils.getTestSuite(select=select))
    suite.addTest(TestFunctions.getTestSuite())
    suite.addTest(TestCombinators.getTestSuite())
    suite.addTest(TestDomHelpers.getTestSuite())
    suite.addTest(TestScanFiles.getTestSuite())
    suite.addTest(TestScanDirectories.getTestSuite())
    suite.addTest(TestNetUtils.getTestSuite())
    suite.addTest(TestSuperGlobal.getTestSuite())
    return suite


from MiscLib import TestUtils

if __name__ == "__main__":
    TestUtils.runTests("TestAll", getTestSuite, sys.argv)

# End.
Exemplo n.º 24
0
    """
    Get test suite

    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": ["testUnits", "testCase", "testArg"],
        "component": ["testComponents"],
        "integration": ["testIntegration"],
        "pending": ["testPending"]
    }
    for (argname, argval) in testargs:
        if argval: setattr(TestExample, argname, argval)
    return TestUtils.getTestSuite(TestExample, testdict, select=select)


# Run unit tests directly from command line
if __name__ == "__main__":
    testargs = [("-a", "--arg", "VAL", "arg", "Argument passed to test suite")]
    TestUtils.runTests("TestTestUtils.log",
                       getTestSuite,
                       sys.argv + ['-a', 'val'],
                       testargs=testargs)

# End.
Exemplo n.º 25
0
def getTestSuite(select="unit"):
    """
    Get test suite

    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": ["testUnits", "testNull"],
        "component": [
            "testComponents", "testReadMe", "testCreateFile",
            "testRewriteFile", "testUpdateFile", "testDeleteFile",
            "testWebDAVFile"
        ],
        "integration": ["testIntegration"],
        "pending": ["testPending"]
    }
    return TestUtils.getTestSuite(TestFileAccess, testdict, select=select)


# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestFileAccess", getTestSuite, sys.argv)

# End.
Exemplo n.º 26
0
        data = self.doQueryPOST(sparqlquery, JSON=True)
        self.assertBindingEqual(data, 0,
                                "An activity can only have one end time")


def getTestSuite(select="unit"):
    """
    Get test suite

    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": [
            "testUniqueGeneration", "testUniqueInvalidation",
            "testUniqueStartedBy", "testUniqueEndedBy", "testUniqueStartTime",
            "testUniqueEndTime"
        ],
    }
    return TestUtils.getTestSuite(TestUniqueness, testdict, select=select)


if __name__ == "__main__":
    TestUtils.runTests("TestUniqueness", getTestSuite, sys.argv)

# End.
Exemplo n.º 27
0
    suite.addTest(TestSubmitDataset.getTestSuite(select=select))
    suite.addTest(TestSubmitDatasetHandler.getTestSuite(select=select))
    suite.addTest(TestDirectoryListingHandler.getTestSuite(select=select))
    suite.addTest(TestMetadataMerging.getTestSuite(select=select))
    suite.addTest(TestGetDatasetMetadataHandler.getTestSuite(select=select))
    suite.addTest(TestHttpSession.getTestSuite(select=select))
    return suite

from MiscLib import TestUtils
import junitxml

if __name__ == "__main__":
    print "============================================================"
    print "This test suite needs to run under a Linux operating system"
    print "Edit TestConfig.py to specify hostname and other parameters"
    print "Create test accounts on target system to match TestConfig.py"
    print "============================================================"
    TestConfig.setDatasetsBaseDir(".")
    
    
    if len(sys.argv) >= 2 and sys.argv[1] == "xml":
        with open('xmlresults.xml', 'w') as report:
            result = junitxml.JUnitXmlResult(report)
            result.startTestRun()
            getTestSuite().run(result)
            result.stopTestRun()
    else:
        TestUtils.runTests("TestAll", getTestSuite, sys.argv)

# End.
Exemplo n.º 28
0
            , "testCreateEventAgent1"
            , "testCreateEventAgentError"
            , "testMakeEventAgent1"
            , "testMakeEventAgent2"
            , "testMakeEventAgent3"
            , "testEventAgentEqual1"
            , "testEventAgentEqual2"
            , "testEventAgentEqual3"
            , "testEventAgentEqual4"
            , "testEventAgentEqual5"
            , "testEventAgentEqual6"
            , "testEventAgentEqual7"
            ],
        "component":
            [ "testComponents"
            ],
        "integration":
            [ "testIntegration"
            ],
        "pending":
            [ "testPending"
            ]
        }
    return TestUtils.getTestSuite(TestEventAgent, testdict, select=select)

# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestEventAgent.log", getTestSuite, sys.argv)

# End.
    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": [  #"testUnits"
            "testDirectoryListingHandlerResponse"
        ],
        "component": [  #"testComponents"
        ],
        "integration": [  #"testIntegration"
        ],
        "pending": [  #"testPending"
        ]
    }
    return TestUtils.getTestSuite(TestDirectoryListingHandler,
                                  testdict,
                                  select=select)


if __name__ == "__main__":
    #logging.basicConfig(level=logging.DEBUG)
    TestConfig.setDatasetsBaseDir(".")
    TestUtils.runTests("TestDirectoryListingHandler.log", getTestSuite,
                       sys.argv)
    #runner = unittest.TextTestRunner()
    #runner.run(getTestSuite())
Exemplo n.º 30
0
import junitxml
logger = logging.getLogger("AllTests")


# Code to run unit tests from all library test modules
def getTestSuite(select="all"):
    suite = unittest.TestSuite()
    suite.addTest(TestAll.getTestSuite(select=select))
    return suite


if __name__ == "__main__":
    print "============================================================"
    print "This test suite needs to run under a Linux operating system"
    print "Edit TestConfig.py to specify hostname and other parameters"
    print "Create test accounts on target system to match TestConfig.py"
    print "============================================================"
    #print repr( commands.getstatusoutput('ls ../../'))
    TestConfig.setDatasetsBaseDir("../../SubmitDatasetHandler/tests")

    if len(sys.argv) >= 2 and sys.argv[1] == "xml":
        with open('xmlresults.xml', 'w') as report:
            result = junitxml.JUnitXmlResult(report)
            result.startTestRun()
            getTestSuite().run(result)
            result.stopTestRun()
    else:
        TestUtils.runTests("AllTests", getTestSuite, sys.argv)

# End.
Exemplo n.º 31
0
            "testUserACreateCIFSCollabReadCIFS",
            "testUserACreateCIFSCollabUpdateCIFS",
            "testUserACreateCIFSCollabDeleteCIFS",
            "testCollabCreateHTTPInUserA",
            "testUserACreateHTTPCollabReadHTTP",
            "testUserACreateHTTPCollabUpdateHTTP",
            "testUserACreateHTTPCollabDeleteHTTP"
            # Test RG Leader's access permissions on files in User A's Private area
            ,
            "testRGLeaderCreateCIFSInUserA",
            "testUserACreateCIFSRGLeaderReadCIFS",
            "testUserACreateCIFSRGLeaderUpdateCIFS",
            "testUserACreateCIFSRGLeaderDeleteCIFS",
            "testRGLeaderCreateHTTPInUserA",
            "testUserACreateHTTPRGLeaderReadHTTP",
            "testUserACreateHTTPRGLeaderUpdateHTTP",
            "testUserACreateHTTPRGLeaderDeleteHTTP"
        ],
        "component": ["testComponents"],
        "integration": ["testIntegration"],
        "pending": ["testPending"]
    }
    return TestUtils.getTestSuite(TestFilePrivateArea, testdict, select=select)


# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestFilePrivateArea.log", getTestSuite, sys.argv)

# End.
Exemplo n.º 32
0
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": ["testUnits", "testNull"],
        "component": [
            "testComponents", "testReadMeCIFS", "testReadMeHTTP",
            "testCreateFileCIFS", "testCreateFileHTTP", "testUpdateFileCIFS",
            "testUpdateFileHTTP"
        ],
        "integration": ["testIntegration"],
        "pending": [
            "testPending", "testReadMeSSH", "testReadMeDAVfs",
            "testCreateFileDAVfs", "testUpdateFileDAVfs",
            "testDeleteFileDAVfs", "testDeleteFileCIFS", "testDeleteFileHTTP"
        ]
    }
    return TestUtils.getTestSuite(TestFileUserASharedPublic,
                                  testdict,
                                  select=select)


# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestFileUserASharedPublic", getTestSuite, sys.argv)

# End.
Exemplo n.º 33
0
    def https_request(self, request):
        credentials = self.passwd.find_user_password(None,
                                                     request.get_full_url())
        if all(credentials):
            request.add_header(
                self.auth_header,
                'Basic %s' % base64.b64encode(':'.join(credentials)))
        return request


# Assemble test suite

from MiscLib import TestUtils


def getTestSuite(select="unit"):
    testdict = {
        "unit": [],
        "component": ["testMe"],
        "integration": ["testIntegration"],
        "pending": ["testPending"]
    }
    return TestUtils.getTestSuite(OXDSDataset, testdict, select=select)


# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("OXDSDataset", getTestSuite, sys.argv)

# End.
            [ "testComponents"
            , "testSharedUserCIFS"
            , "testSharedUserHTTP"
            , "testSharedUserHTTPB"
            , "testSharedUserHTTPRGLeader"
            , "testSharedUserHTTPCollab"
            ],
        "integration":
            [ "testIntegration"
            ],
        "pending":
            [ "testPending"
            , "testReadMeSSH"
            , "testReadMeDAVfs"
            , "testCreateFileDAVfs"
            , "testUpdateFileDAVfs"
            , "testDeleteFileDAVfs"
            , "testDeleteFileCIFS"
            , "testDeleteFileHTTP"
            ]
        }
    return TestUtils.getTestSuite(TestFileCollabArea, testdict, select=select)

# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestFileCollabArea", getTestSuite, sys.argv)

# End.


Exemplo n.º 35
0
    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit":
            [ 
             "testGenerationPrecedesInvalidation",
             "testGenerationPrecedesUsage",
             "testUsagePrecedesInvalidation",
             "testGenerationOrdering",
             "testInvalidationOrdering",
             "testDerivationUsageGenerationOrdering",
             "testDerivationGenerationGenerationOrdering",
             "testWasStartedByOrdering",
             "testWasEndedByOrdering",
             "testSpecializationGenerationOrdering",
             "testSpecializationInvalidationOrdering"
            ],
        }
    return TestUtils.getTestSuite(TestEntityOrdering, testdict, select=select)

if __name__ == "__main__":
    TestUtils.runTests("TestEntityOrdering", getTestSuite, sys.argv)

# End.
    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": [
            "testRunASK", "testRUNSELECT1", "testNumberOfWorkflowOutputsCOUNT",
            "testNumberOfWorkflowInputsCOUNT",
            "testWorkflowInputPatternSELECT", "testNumberOfProcessRunsCount",
            "testNumberOfProcessRunsCount2", "testStartTimeOfRunSelect",
            "testEndTimeOfRunSelect", "testSourceArtifactsOfWfOutputCount",
            "testSourceActivitiesOfWfOutputCount",
            "testAllSourceArtifactsOfWfOutputCount",
            "testAllSourceActivitiesOfWfOutputCount", "testOutputOfHelloCount",
            "testInputsOfConcatenateCount", "testStartTimeOfConcatenateSelect",
            "testEndTimeOfConcatenateSelect"
        ],
    }
    return TestUtils.getTestSuite(TestHelloAnyoneHandmade,
                                  testdict,
                                  select=select)


if __name__ == "__main__":
    TestUtils.runTests("TestHelloAnyoneHandmade", getTestSuite, sys.argv)

# End.
Exemplo n.º 37
0
    """
    testdict = {
        "unit": 
            [ "testUnits"
            , "testNull"
            ],
        "component":
            [ "testComponents"
            , "testWebDAVFileRead"
            , "testWebDAVFileCreate"
            , "testWebDAVFileUpdate"
            ],
        "integration":
            [ "testIntegration"
            ],
        "pending":
            [ "testPending"
            , "testWebDAVFile"
            , "testWebDAVFileDelete"
            ]
        }
    return TestUtils.getTestSuite(TestWebDAVbyHTTP, testdict, select=select)

# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestWebDAVbyHTTP", getTestSuite, sys.argv)

# End.


Exemplo n.º 38
0
            , "testWatch1"
            , "testWatch2"
            , "testWatch3"
            , "testWatch4"
            , "testWatch5"
            , "testWatch6"
            , "testWatch7"
            , "testWatchPrior1"
            , "testWatchPrior2"
            , "testWatchPrior3"
            , "testWatchPrior4"
            ],
        "component":
            [ "testComponents"
            ],
        "integration":
            [ "testIntegration"
            ],
        "pending":
            [ "testPending"
            , "testWatch8"
            ]
        }
    return TestUtils.getTestSuite(TestEventPubSub, testdict, select=select)

# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestEventPubSub.log", getTestSuite, sys.argv)

# End.
Exemplo n.º 39
0
            , "testUserACreateHTTPCollabDeleteHTTP"       
            # Test RG Leader's access permissions on files in User A's Shared area     
            , "testRGLeaderCreateCIFSInUserA"
            , "testUserACreateCIFSRGLeaderReadCIFS"
            , "testUserACreateCIFSRGLeaderUpdateCIFS"
            , "testUserACreateCIFSRGLeaderDeleteCIFS"
            , "testRGLeaderCreateHTTPInUserA"
            , "testUserACreateHTTPRGLeaderReadHTTP"
            , "testUserACreateHTTPRGLeaderUpdateHTTP"
            , "testUserACreateHTTPRGLeaderDeleteHTTP"
            ],
        "component":
            [ "testComponents"
            ],
        "integration":
            [ "testIntegration"
            ],
        "pending":
            [ "testPending"
            ]
        }
    return TestUtils.getTestSuite(TestFileSharedArea, testdict, select=select)

# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestFileSharedArea.log", getTestSuite, sys.argv)

# End.


Exemplo n.º 40
0
    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": 
            [
              "GetEvents"            
            , "DecodeMessage"
            , "DecodeMultiple"
            , "DecodeDirtyMessage"
            ],
        "component":
            [ "testDummy"
            ],
        "integration":
            [ "testDummy"
            ],
        "pending":
            [ "testDummy"
            ]
        }
    return TestUtils.getTestSuite(TestSkyDrivers, testdict, select=select)

# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestSkyDrivers.log", getTestSuite, sys.argv)
    Get test suite

    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit":
            [ #"testUnits"
              "testGetDatasetMetadataResponse"
            ],
        "component":
            [ #"testComponents"
            ],
        "integration":
            [ #"testIntegration"
            ],
        "pending":
            [ #"testPending"
            ]
        }
    return TestUtils.getTestSuite(TestGetDatasetMetadataHandler, testdict, select=select)

if __name__ == "__main__":
    #logging.basicConfig(level=logging.DEBUG)
    TestConfig.setDatasetsBaseDir(".")
    TestUtils.runTests("TestGetDatasetMetadataHandler.log", getTestSuite, sys.argv)
Exemplo n.º 42
0
    Get test suite

    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be testSimpleHttpGet_origrun
    """
    testdict = {
        "unit": [  #"testUnits"
            #"testSimpleHttpGet_orig",
            "testSimpleHttpGet",
            "testSimpleHttpPost",
            "testSimpleHttpDelete"
        ],
        "component": [  #"testComponents"
        ],
        "integration": [  #"testIntegration"
        ],
        "pending": [  #"testPending"
        ]
    }
    return TestUtils.getTestSuite(TestHttpSession, testdict, select=select)


if __name__ == "__main__":
    logging.basicConfig(level=logging.DEBUG)
    TestConfig.setDatasetsBaseDir(".")
    TestUtils.runTests("TestHttpSession.log", getTestSuite, sys.argv)
Exemplo n.º 43
0
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": 
            [ "testUnits"
            , "testNull"
            ,"testDatasetSubmission"
            ],
        "component":
            [ "testComponents"
            ],
        "integration":
            [ "testIntegration"
            ],
        "pending":
            [ 

            ]
        }
    return TestUtils.getTestSuite(TestDatasetSubmission, testdict, select=select)

# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestDatasetSubmission", getTestSuite, sys.argv)

# End.


Exemplo n.º 44
0
    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit":
            [ "testUnits"
            , "testNull"
            , "testTripleExists"
            , "testSimpleJSONDecode"
            ],
        "component":
            [ "testComponents"
            ],
        "integration":
            [ "testIntegration"
            ],
        "pending":
            [ "testPending"
            ]
        }
    return TestUtils.getTestSuite(SparqlQueryTestCase, testdict, select=select)

if __name__ == "__main__":
    TestUtils.runTests("SparqlQueryTestCase", getTestSuite, sys.argv)

# End.
Exemplo n.º 45
0
            , "testMultipleFilesLocal"
            , "testMultipleFilesLocalCleanUp"
            , "testMultipleFilesAbsoluteLocal"
            , "testSingleDirectoryAbsoluteLocal"
            , "testSingleDirectoryRecursiveAbsoluteLocal"
            , "testMultipleDirectorysLocal"
            , "testMixedDataSetLocal"
            , "testMultipleFileChangeLocal"
            , "testMixedDataSetChangeLocal"
            , "testMultipleFileDeltaLocal"
            , "testMixedDataSetDeltaLocal"
            , "testCommandLine"
            ],
        "zzcomponent":
            [ "testComponents"
            ],
        "integration":
            [ "testSingleDirectoryHttpS"
             ,"testSingleDirectoryFtp"
            ],
        "zzpending":
            [ "testPending"
            ]
        }
    return TestUtils.getTestSuite(TestBackupHandler, testdict, select=select)

# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestBackupHandler.log", getTestSuite, sys.argv)

    Get test suite

    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit":
            [ #"testUnits"
              "testAdmiralModifyUserDetails"
            ],
        "component":
            [ #"testComponents"
            ],
        "integration":
            [ #"testIntegration"
            ],
        "pending":
            [ #"testPending"
            ]
        }
    return TestUtils.getTestSuite(TestAdminInterfaceRestfulAPIs, testdict, select=select)

if __name__ == "__main__":
    #logging.basicConfig(level=logging.DEBUG)
    TestUtils.runTests("TestAdminInterfaceRestfulAPIs.log", getTestSuite, sys.argv)
    #runner = unittest.TextTestRunner()
    #runner.run(getTestSuite())
Exemplo n.º 47
0
def getTestSuite(select="unit"):
    """
    Get test suite

    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": 
            [ "testEventLogger"
            ],
        "component":
            [ "testDummy"
            ],
        "integration":
            [ "testDummy"
            ],
        "pending":
            [ "testDummy"
            ]
        }
    return TestUtils.getTestSuite(TestLogEvents, testdict, select=select)

# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestLogEvents.log", getTestSuite, sys.argv)
Exemplo n.º 48
0
            "testUserACreateCIFSCollabReadCIFS",
            "testUserACreateCIFSCollabUpdateCIFS",
            "testUserACreateCIFSCollabDeleteCIFS",
            "testCollabCreateHTTPInUserA",
            "testUserACreateHTTPCollabReadHTTP",
            "testUserACreateHTTPCollabUpdateHTTP",
            "testUserACreateHTTPCollabDeleteHTTP"
            # Test RG Leader's access permissions on files in User A's Private area
            ,
            "testRGLeaderCreateCIFSInUserA",
            "testUserACreateCIFSRGLeaderReadCIFS",
            "testUserACreateCIFSRGLeaderUpdateCIFS",
            "testUserACreateCIFSRGLeaderDeleteCIFS",
            "testRGLeaderCreateHTTPInUserA",
            "testUserACreateHTTPRGLeaderReadHTTP",
            "testUserACreateHTTPRGLeaderUpdateHTTP",
            "testUserACreateHTTPRGLeaderDeleteHTTP"
        ],
        "component": ["testComponents"],
        "integration": ["testIntegration"],
        "pending": ["testPending"]
    }
    return TestUtils.getTestSuite(TestFileCommonArea, testdict, select=select)


# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestFileCommonArea.log", getTestSuite, sys.argv)

# End.
    """
    testdict = {
        "unit":
            [ 
             "testRUNOfAWorkflow",
             "testRUNOfAWorkflow2",
             "testNumberOfWorkflowOutputsCOUNT",
             "testNumberOfWorkflowOutputsCOUNTProv",
             "testNumberOfWorkflowInputsCOUNT",
             "testNumberOfWorkflowInputsCOUNTProv",
             "testWorkflowInputPatternSELECT",
             "testNumberOfProcessRunsCount",
             "testStartTimeOfRunSelect",
             "testEndTimeOfRunSelect",
             "testSourceArtifactsOfWfOutputCount",
             "testSourceActivitiesOfWfOutputCount",
             "testOutputOfConcatenateCount",
             "testInputsOfConcatenateCount",
             "testStartTimeOfConcatenateSelect",
             "testEndTimeOfConcatenateSelect",
             "testIntermediateOutputsCount",
             "testIntermediateInputsCount"
            ],
        }
    return TestUtils.getTestSuite(TestHelloAnyoneWfprov, testdict, select=select)

if __name__ == "__main__":
    TestUtils.runTests("TestHelloAnyoneWfprov", getTestSuite, sys.argv)

# End.
Exemplo n.º 50
0

def getTestSuite(select="unit"):
    """
    Get test suite

    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
             name       a single named test to be run
    """
    testdict = {
        "unit": [
            "testReadMetadata",
            "testUpdateMetadata",
            "testGetElementValuesFromManifest",
            "testGetDictionaryFromManifest",
        ],
        "component": [],  # "testComponents"
        "integration": [],  # "testIntegration"
        "pending": [],  # "testPending"
    }
    return TestUtils.getTestSuite(TestMetadataMerging, testdict, select=select)


if __name__ == "__main__":
    TestConfig.setDatasetsBaseDir(".")
    TestUtils.runTests("TestMetadataMerging.log", getTestSuite, sys.argv)
Exemplo n.º 51
0
    Get test suite

    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "zzunit": 
            [ "testDummy"
            ],
        "zzcomponent":
            [ "testDummy"
            ],
        "integration":
            [ "testSend"
            , "testListen"
            ],
        "zzpending":
            [ "testDummy"
            ]
        }
    return TestUtils.getTestSuite(TestCounters, testdict, select=select)

# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestCounters.log", getTestSuite, sys.argv)

Exemplo n.º 52
0

# Assemble test suite


def getTestSuite(select="unit"):
    """
    Get test suite

    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit":
        ["testUnits", "testNull", "testTripleExists", "testSimpleJSONDecode"],
        "component": ["testComponents"],
        "integration": ["testIntegration"],
        "pending": ["testPending"]
    }
    return TestUtils.getTestSuite(SparqlQueryTestCase, testdict, select=select)


if __name__ == "__main__":
    TestUtils.runTests("SparqlQueryTestCase", getTestSuite, sys.argv)

# End.
Exemplo n.º 53
0
# Assemble test suite

from MiscLib import TestUtils

def getTestSuite(select="unit"):
	testdict = {
		"unit": 
			[ 
			],
		"component":
			[ "testMe"
			],
		"integration":
			[ "testIntegration"
			],
		"pending":
			[ "testPending"
			]
		}
	return TestUtils.getTestSuite(OXDSDataset, testdict, select=select)

# Run unit tests directly from command line
if __name__ == "__main__":
	TestUtils.runTests("OXDSDataset", getTestSuite, sys.argv)

# End.


                   
Exemplo n.º 54
0
            ],
        "integration":
            [ "testIntegration"
            , "verifyVersion"
            , "verifyName"
            , "verifyNodeNumber"
            , "verifyFadeRate"
            , "verifyIp"
            , "verifyMacAddress"
            , "verifyRotary"
            , "verifyDwellConfiguration"
            , "verifySetPointConfiguration"
            , "verifyDoNameConfiguration"
            , "verifyAoNameConfiguration"
            , "verifyDigitalIn"
            , "verifyTemperatures"
            , "verifyAnalogueIn"
            , "verifySchedules"
            , "verifyScenes"
            ],
        "pending":
            [ "testPending"
            ]
        }
    return TestUtils.getTestSuite(TestWb6Config, testdict, select=select)

# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestWb6Config.log", getTestSuite, sys.argv)

Exemplo n.º 55
0

def getTestSuite(select="unit"):
    """
    Get test suite

    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": [
            "testUnits", "testDate1", "testTime1", "testDateTime1",
            "testDateTime2"
        ],
        "component": ["testComponents"],
        "integration": ["testIntegration"],
        "pending": ["testPending"]
    }
    return TestUtils.getTestSuite(TestURI, testdict, select=select)


# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestURI.log", getTestSuite, sys.argv)

# End.
Exemplo n.º 56
0
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": 
            [ "testUnits"
            ],
        "component":
            [ "testComponents"
            ],
        "integration":
            [ "testIntegration"
            , "testTestEventHTTPClientIntro"
            , "testSubscriptionForwarding1"
            , "testSubscriptionForwarding2"
            , "testSubscriptionForwarding3"
            , "testSubscriptionForwarding4"
            , "testTestEventHTTPClientDone"
            ],
        "pending":
            [ "testPending"
            ]
        }
    return TestUtils.getTestSuite(TestEventHTTPClient, testdict, select=select)

# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestEventHTTPClient.log", getTestSuite, sys.argv)

# End.
Exemplo n.º 57
0
            , "testStatusEqual1"
            , "testStatusEqual2"
            , "testStatusEqual3"
            , "testStatusString1"
            , "testStatusString2"
            , "testStatusString3"
            , "testStatusString4"
            , "testStatusException1"
            , "testStatusException2"
            , "testStatusEvent1"
            , "testStatusEvent2"
            , "testStatusValues"
            ],
        "component":
            [ "testComponents"
            ],
        "integration":
            [ "testIntegration"
            ],
        "pending":
            [ "testPending"
            ]
        }
    return TestUtils.getTestSuite(TestStatusVals, testdict, select=select)

# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestStatus.log", getTestSuite, sys.argv)

# End.
Exemplo n.º 58
0
# Assemble test suite
from MiscLib import TestUtils


def getTestSuite(select="unit"):
    """
    Get test suite

    select  is one of the following:
            "unit"      return suite of unit tests only
            "component" return suite of unit and component tests
            "all"       return suite of unit, component and integration tests
            "pending"   return suite of pending tests
            name        a single named test to be run
    """
    testdict = {
        "unit": ["testUnits", "testMakeDeferred"],
        "component": ["testComponents"],
        "integration": ["testIntegration"],
        "pending": ["testPending"]
    }
    return TestUtils.getTestSuite(TestSyncDeferred, testdict, select=select)


# Run unit tests directly from command line
if __name__ == "__main__":
    TestUtils.runTests("TestSyncDeferred.log", getTestSuite, sys.argv)

# End.