datadir = '/var/lib/jenkins/workspace/DLDSVN/tests-on-diff/.tox/py3/lib/python3.7/site-packages/swh/loader/svn/tests/data'
tmp_path = PosixPath('/tmp/pytest-of-jenkins/pytest-0/test_init_svn_repo_from_archiv1')
def test_init_svn_repo_from_archive_dump_and_cleanup(datadir, tmp_path):
"""Mounting svn repository out of a dump is ok"""
dump_name = "penguinsdbtools2018.dump.gz"
dump_ori_path = os.path.join(datadir, dump_name)
dump_path = os.path.join(tmp_path, dump_name)
> shutil.copyfile(dump_ori_path, dump_path)
.tox/py3/lib/python3.7/site-packages/swh/loader/svn/tests/test_utils.py:97:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
src = '/var/lib/jenkins/workspace/DLDSVN/tests-on-diff/.tox/py3/lib/python3.7/site-packages/swh/loader/svn/tests/data/penguinsdbtools2018.dump.gz'
dst = '/tmp/pytest-of-jenkins/pytest-0/test_init_svn_repo_from_archiv1/penguinsdbtools2018.dump.gz'
def copyfile(src, dst, *, follow_symlinks=True):
"""Copy data from src to dst.
If follow_symlinks is not set and src is a symbolic link, a new
symlink will be created instead of copying the file it points to.
"""
if _samefile(src, dst):
raise SameFileError("{!r} and {!r} are the same file".format(src, dst))
for fn in [src, dst]:
try:
st = os.stat(fn)
except OSError:
# File most likely does not exist
pass
else:
# XXX What about other special files? (sockets, devices...)
if stat.S_ISFIFO(st.st_mode):
raise SpecialFileError("`%s` is a named pipe" % fn)
if not follow_symlinks and os.path.islink(src):
os.symlink(os.readlink(src), dst)
else:
> with open(src, 'rb') as fsrc:
E FileNotFoundError: [Errno 2] No such file or directory: '/var/lib/jenkins/workspace/DLDSVN/tests-on-diff/.tox/py3/lib/python3.7/site-packages/swh/loader/svn/tests/data/penguinsdbtools2018.dump.gz'
/usr/lib/python3.7/shutil.py:120: FileNotFoundError
TEST RESULT
TEST RESULT
- Run At
- Nov 9 2021, 11:24 AM