Fix integration tests
This commit is contained in:
@@ -1,6 +1,8 @@
|
|||||||
#!/usr/bin/env python3
|
#!/usr/bin/env python3
|
||||||
import subprocess
|
import subprocess
|
||||||
from subprocess import DEVNULL, PIPE
|
from subprocess import DEVNULL, PIPE
|
||||||
|
import shutil
|
||||||
|
from pathlib import Path
|
||||||
import tempfile
|
import tempfile
|
||||||
import json
|
import json
|
||||||
import sys
|
import sys
|
||||||
@@ -98,6 +100,11 @@ def main(tempdir, binary):
|
|||||||
('https://www.example.com/', 200),
|
('https://www.example.com/', 200),
|
||||||
}
|
}
|
||||||
|
|
||||||
|
cache = Path.home() / '.cache' / 'sn0int'
|
||||||
|
if cache.exists():
|
||||||
|
print('[*] copying geoip files')
|
||||||
|
shutil.copytree(cache, tempdir + '/.cache/sn0int', dirs_exist_ok=True)
|
||||||
|
|
||||||
print('[*] running geoip')
|
print('[*] running geoip')
|
||||||
sn0int(tempdir, binary, [
|
sn0int(tempdir, binary, [
|
||||||
'use geoip',
|
'use geoip',
|
||||||
|
|||||||
Reference in New Issue
Block a user