def test_get_installdir(self): '''get install directory should return the base of where singularity is installed ''' print("Testing utils.get_installdir") from spython.utils import get_installdir whereami = get_installdir() print(whereami) self.assertTrue('spython' in whereami)
def test_get_installdir(): """get install directory should return the base of where singularity is installed """ print("Testing utils.get_installdir") from spython.utils import get_installdir whereami = get_installdir() print(whereami) assert whereami.endswith("spython")
def sandbox(tmp_path): image = Client.build("docker://busybox:1.30.1", image=str(tmp_path / 'sandbox'), sandbox=True, sudo=False) assert os.path.exists(image) config = os.path.join(get_installdir(), 'oci', 'config.json') shutil.copyfile(config, os.path.join(image, 'config.json')) return image
def installdir(): return get_installdir()
def setUp(self): self.pwd = get_installdir() self.tmpdir = tempfile.mkdtemp()