From 6e5bd7abd9799b177d3bca005e0d93ce56cf16f8 Mon Sep 17 00:00:00 2001 From: Raymond Ho Date: Mon, 18 Sep 2023 08:48:03 -0700 Subject: [PATCH] disable ldap tests for arm (#23118) --- changelog/23118.txt | 3 +++ helper/testhelpers/ldap/ldaphelper.go | 8 ++++++++ 2 files changed, 11 insertions(+) create mode 100644 changelog/23118.txt diff --git a/changelog/23118.txt b/changelog/23118.txt new file mode 100644 index 0000000000..f931386529 --- /dev/null +++ b/changelog/23118.txt @@ -0,0 +1,3 @@ +```release-note:bug +ldaputil: Disable tests for ARM64 +``` diff --git a/helper/testhelpers/ldap/ldaphelper.go b/helper/testhelpers/ldap/ldaphelper.go index a659b50294..e206d10795 100644 --- a/helper/testhelpers/ldap/ldaphelper.go +++ b/helper/testhelpers/ldap/ldaphelper.go @@ -6,6 +6,8 @@ package ldap import ( "context" "fmt" + "runtime" + "strings" "testing" "github.com/hashicorp/cap/ldap" @@ -15,6 +17,12 @@ import ( ) func PrepareTestContainer(t *testing.T, version string) (cleanup func(), cfg *ldaputil.ConfigEntry) { + // note: this image isn't supported on arm64 architecture in CI. + // but if you're running on Apple Silicon, feel free to comment out the code below locally. + if strings.Contains(runtime.GOARCH, "arm") { + t.Skip("Skipping, as this image is not supported on ARM architectures") + } + runner, err := docker.NewServiceRunner(docker.RunOptions{ // Currently set to "michelvocks" until https://github.com/rroemhild/docker-test-openldap/pull/14 // has been merged.