예제 #1
0
def test_generate_license():
    py.test.skip(
        'generation of license from platform documentation is disabled')
    from os.path import dirname, abspath, join, exists

    class Options(object):
        pass

    options = Options()
    basedir = dirname(dirname(dirname(dirname(dirname(abspath(__file__))))))
    options.no_tk = False
    if sys.platform == 'win32':
        for p in [
                join(basedir, r'..\..\..\local'),  #buildbot
                join(basedir, r'..\local')
        ]:  # pypy/doc/windows.rst
            if exists(p):
                license_base = p
                break
        else:
            license_base = 'unkown'
        options.license_base = license_base
    else:
        options.license_base = '/usr/share/doc'
    license = package.generate_license(py.path.local(basedir), options)
    assert 'bzip2' in license
    assert 'openssl' in license
    assert 'Tcl' in license
예제 #2
0
def test_generate_license():
    py.test.skip('generation of license from platform documentation is disabled')
    from os.path import dirname, abspath, join, exists
    class Options(object):
        pass
    options = Options()
    basedir = dirname(dirname(dirname(dirname(dirname(abspath(__file__))))))
    options.no_tk = False
    if sys.platform == 'win32':
        for p in [join(basedir, r'..\..\..\local'), #buildbot
                  join(basedir, r'..\local')]: # pypy/doc/windows.rst
            if exists(p):
                license_base = p
                break
        else:
            license_base = 'unkown'
        options.license_base = license_base
    else:
        options.license_base = '/usr/share/doc'
    license = package.generate_license(py.path.local(basedir), options)
    assert 'bzip2' in license
    assert 'openssl' in license
    assert 'Tcl' in license
예제 #3
0
def test_generate_license():
    py.test.skip("generation of license from platform documentation is disabled")
    from os.path import dirname, abspath, join, exists

    class Options(object):
        pass

    options = Options()
    basedir = dirname(dirname(dirname(dirname(dirname(abspath(__file__))))))
    options.no_tk = False
    if sys.platform == "win32":
        for p in [join(basedir, r"..\..\..\local"), join(basedir, r"..\local")]:  # buildbot  # pypy/doc/windows.rst
            if exists(p):
                license_base = p
                break
        else:
            license_base = "unkown"
        options.license_base = license_base
    else:
        options.license_base = "/usr/share/doc"
    license = package.generate_license(py.path.local(basedir), options)
    assert "bzip2" in license
    assert "openssl" in license
    assert "Tcl" in license