MCPcopy Create free account
hub / github.com/cloudflare/cfssl / TestBadAuthRemoteConfig

Function TestBadAuthRemoteConfig

config/config_test.go:572–592  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

570}
571
572func TestBadAuthRemoteConfig(t *testing.T) {
573 _, err := LoadConfig([]byte(invalidRemoteConfig))
574 if err == nil {
575 t.Fatal("load invalid config should failed")
576 }
577
578 _, err = LoadConfig([]byte(invalidAuthRemoteConfigMissingRemote))
579 if err == nil {
580 t.Fatal("load invalid config should failed")
581 }
582
583 _, err = LoadConfig([]byte(invalidAuthRemoteConfigMissingKey))
584 if err == nil {
585 t.Fatal("load invalid config should failed")
586 }
587
588 var p *Signing
589 if p.Valid() {
590 t.Fatal("nil Signing config should be invalid")
591 }
592}
593
594func TestValidCAConstraint(t *testing.T) {
595 for _, config := range validLocalConfigsWithCAConstraint {

Callers

nothing calls this directly

Calls 2

ValidMethod · 0.95
LoadConfigFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…