aboutsummaryrefslogtreecommitdiffstats
path: root/lib/crypto/gpg/gpg_test.go
diff options
context:
space:
mode:
authorRobin Jarry <robin@jarry.cc>2023-04-23 21:40:19 +0200
committerRobin Jarry <robin@jarry.cc>2023-04-24 09:49:00 +0200
commit59ce0a11911d7b5fbda6a91b900aabebae55cbea (patch)
tree1023404b0ccf549fea8c61f7e0af88f79a258161 /lib/crypto/gpg/gpg_test.go
parente7aefcaff8fcbc6fa6f2a424e1662c1e9cf6839f (diff)
downloadaerc-59ce0a11911d7b5fbda6a91b900aabebae55cbea.tar.gz
mod: drop support for go 1.17
A lot of libraries are starting to use generics (introduced in go 1.18). Restricting aerc on 1.17 prevents us from updating our dependencies. Since 1.18 is a major milestone, it has a chance to remain supported for a while. Update the minimum go version to 1.18. Run go mod tidy -compat=1.18. Update our CI to run on 1.18. Signed-off-by: Robin Jarry <robin@jarry.cc> Acked-by: Bence Ferdinandy <bence@ferdinandy.com>
Diffstat (limited to 'lib/crypto/gpg/gpg_test.go')
-rw-r--r--lib/crypto/gpg/gpg_test.go9
1 files changed, 1 insertions, 8 deletions
diff --git a/lib/crypto/gpg/gpg_test.go b/lib/crypto/gpg/gpg_test.go
index e34cc2bb..25d73693 100644
--- a/lib/crypto/gpg/gpg_test.go
+++ b/lib/crypto/gpg/gpg_test.go
@@ -3,7 +3,6 @@ package gpg
import (
"bytes"
"io"
- "os"
"os/exec"
"strings"
"testing"
@@ -17,13 +16,7 @@ func initGPGtest(t *testing.T) {
}
// temp dir is automatically deleted by the test runtime
dir := t.TempDir()
- // t.Setenv is only available since go 1.17
- if err := os.Setenv("GNUPGHOME", dir); err != nil {
- t.Fatalf("failed to set GNUPGHOME: %s", err)
- }
- t.Cleanup(func() {
- os.Unsetenv("GNUPGHOME")
- })
+ t.Setenv("GNUPGHOME", dir)
t.Logf("using GNUPGHOME = %s", dir)
}