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')
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')