1
0
Fork 0
mirror of https://github.com/Mic92/sops-nix.git synced 2025-03-13 20:29:17 +00:00

Merge pull request #52 from Mic92/fix-tests2

ssh-to-pgp: fix tests
This commit is contained in:
Jörg Thalheim 2020-12-15 03:18:05 +00:00 committed by GitHub
commit 797e755277
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -30,8 +30,10 @@ func TempRoot() string {
}
func TestCli(t *testing.T) {
_, filename, _, _ := runtime.Caller(0)
assets := path.Join(path.Dir(filename), "test-assets")
assets := os.Getenv("TEST_ASSETS")
if assets == "" {
assets = "test-assets"
}
tempdir, err := ioutil.TempDir(TempRoot(), "testdir")
ok(t, err)
defer os.RemoveAll(tempdir)