예제 #1
0
파일: test_api.py 프로젝트: mozillazg/pypy
def test_copy_header_files(tmpdir):
    api.copy_header_files(tmpdir, True)
    def check(name):
        f = tmpdir.join(name)
        assert f.check(file=True)
        py.test.raises(py.error.EACCES, "f.open('w')") # check that it's not writable
    check('Python.h')
    check('modsupport.h')
    check('pypy_decl.h')
예제 #2
0
def test_copy_header_files(tmpdir):
    copy_header_files(cts, tmpdir, True)
    def check(name):
        f = tmpdir.join(name)
        assert f.check(file=True)
        py.test.raises(py.error.EACCES, "f.open('w')") # check that it's not writable
    check('Python.h')
    check('modsupport.h')
    check('pypy_decl.h')