예제 #1
0
파일: test_css.py 프로젝트: lrowe/lxml
def test_suite():
    suite = unittest.TestSuite()
    if sys.version_info >= (2, 4):
        suite.addTests([make_doctest('test_css_select.txt')])
    suite.addTests([make_doctest('test_css.txt')])
    suite.addTests(doctest.DocTestSuite(cssselect))
    suite.addTests(list(CSSTestCase.all()))
    return suite
예제 #2
0
def test_suite():
    suite = unittest.TestSuite()
    try:
        import cssselect
    except ImportError:
        # no 'cssselect' installed
        print("Skipping tests in lxml.cssselect - external cssselect package is not installed")
        return suite

    import lxml.cssselect
    suite.addTests(doctest.DocTestSuite(lxml.cssselect))
    suite.addTests([unittest.makeSuite(CSSTestCase)])
    return suite
예제 #3
0
def test_suite():
    suite = unittest.TestSuite()
    suite.addTests([make_doctest("test_basic.txt")])
    suite.addTests([doctest.DocTestSuite(lxml.html)])
    return suite
예제 #4
0
def test_suite():
    suite = unittest.TestSuite()
    if sys.version_info >= (2,4):
        suite.addTests([make_doctest('test_diff.txt'),
                        doctest.DocTestSuite(diff)])
    return suite
예제 #5
0
def test_suite():
    suite = unittest.TestSuite()
    if sys.version_info >= (2,4):
        suite.addTests([make_doctest('test_basic.txt')])
    suite.addTests([doctest.DocTestSuite(lxml.html)])
    return suite
예제 #6
0
def test_suite():
    suite = unittest.TestSuite()
    suite.addTests([make_doctest("test_diff.txt"), doctest.DocTestSuite(diff)])
    return suite