tests - remove only content of subfolders

This commit is contained in:
bunkerity 2022-07-21 15:26:59 +02:00
parent 4eff0c3f9d
commit 3a46d318ee
No known key found for this signature in database
GPG Key ID: 3D80806F12602A7C
1 changed files with 1 additions and 1 deletions

View File

@ -50,7 +50,7 @@ class Test(ABC) :
rm_dirs = ["configs", "plugins", "www"]
for rm_dir in rm_dirs :
if isdir("/tmp/bw-data/" + rm_dir) :
run("sudo rm -rf /tmp/bw-data/" + rm_dir, shell=True)
run("sudo rm -rf /tmp/bw-data/" + rm_dir + "/*", shell=True)
if isdir("/tmp/tests/" + self._name) :
run("sudo rm -rf /tmp/tests/" + self._name, shell=True)
copytree("./examples/" + self._name, "/tmp/tests/" + self._name)