Fix tests for ACME Wire provisioner

This commit is contained in:
Herman Slatman
2024-01-10 20:23:01 +01:00
parent 8997ce1a1e
commit ffd887f8cc
2 changed files with 16 additions and 3 deletions

View File

@@ -1695,7 +1695,7 @@ func TestHandler_NewOrder(t *testing.T) {
}
},
"ok/default-naf-nbf-wireapp": func(t *testing.T) test {
acmeWireProv := newACMEProvWithOptions(t, &provisioner.Options{
acmeWireProv := newWireProvisionerWithOptions(t, &provisioner.Options{
OIDC: &provisioner.OIDCOptions{
Provider: provisioner.ProviderJSON{
IssuerURL: "",

View File

@@ -36,8 +36,21 @@ const (
linkerPrefix = "acme"
)
func TestIMIntegration(t *testing.T) {
prov := newACMEProvWithOptions(t, &provisioner.Options{
func newWireProvisionerWithOptions(t *testing.T, options *provisioner.Options) *provisioner.ACME {
p := newProvWithOptions(options)
a, ok := p.(*provisioner.ACME)
if !ok {
t.Fatal("not a valid ACME provisioner")
}
a.Challenges = []provisioner.ACMEChallenge{
provisioner.WIREOIDC_01,
provisioner.WIREDPOP_01,
}
return a
}
func TestWireIntegration(t *testing.T) {
prov := newWireProvisionerWithOptions(t, &provisioner.Options{
OIDC: &provisioner.OIDCOptions{
Provider: provisioner.ProviderJSON{
IssuerURL: "",