Add godocs for fixtures
... and rename `InvalidCaCertPath` to `InvalidCertPath`.
This commit is contained in:
parent
0cbe25436d
commit
795e4c4254
@ -103,7 +103,7 @@ func TestInvalidCaCert(t *testing.T) {
|
||||
connection := &vclib.VSphereConnection{
|
||||
Hostname: "should-not-matter",
|
||||
Port: "should-not-matter",
|
||||
CACert: fixtures.InvalidCaCertPath,
|
||||
CACert: fixtures.InvalidCertPath,
|
||||
}
|
||||
|
||||
_, err := connection.NewClient(context.Background())
|
||||
|
@ -24,10 +24,17 @@ import (
|
||||
)
|
||||
|
||||
var (
|
||||
CaCertPath string
|
||||
ServerCertPath string
|
||||
ServerKeyPath string
|
||||
InvalidCaCertPath string
|
||||
// CaCertPath is the filepath to a certificate that can be used as a CA
|
||||
// certificate.
|
||||
CaCertPath string
|
||||
// ServerCertPath is the filepath to a leaf certifiacte signed by the CA at
|
||||
// `CaCertPath`.
|
||||
ServerCertPath string
|
||||
// ServerKeyPath is the filepath to the private key for the ceritifiacte at
|
||||
// `ServerCertPath`.
|
||||
ServerKeyPath string
|
||||
// InvalidCertPath is the filepath to an invalid certificate.
|
||||
InvalidCertPath string
|
||||
)
|
||||
|
||||
func init() {
|
||||
@ -54,5 +61,5 @@ func init() {
|
||||
CaCertPath = filepath.Join(fixturesDir, "ca.pem")
|
||||
ServerCertPath = filepath.Join(fixturesDir, "server.pem")
|
||||
ServerKeyPath = filepath.Join(fixturesDir, "server.key")
|
||||
InvalidCaCertPath = filepath.Join(fixturesDir, "invalid.pem")
|
||||
InvalidCertPath = filepath.Join(fixturesDir, "invalid.pem")
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user