Fixes test case failure due to moving constants
Signed-off-by: Zhongcheng Lao <Zhongcheng.Lao@microsoft.com>pull/5015/head
parent
63fdde280f
commit
253d658ad3
|
@ -56,10 +56,10 @@ func TestSetupCerts(t *testing.T) {
|
||||||
cmdMap := map[string]string{}
|
cmdMap := map[string]string{}
|
||||||
certFilenames := map[string]string{"ca.crt": "minikubeCA.pem", "mycert.pem": "mycert.pem"}
|
certFilenames := map[string]string{"ca.crt": "minikubeCA.pem", "mycert.pem": "mycert.pem"}
|
||||||
for _, dst := range certFilenames {
|
for _, dst := range certFilenames {
|
||||||
certFile := path.Join(constants.CACertificatesDir, dst)
|
certFile := path.Join(CACertificatesDir, dst)
|
||||||
certStorePath := path.Join(constants.SSLCertStoreDir, dst)
|
certStorePath := path.Join(SSLCertStoreDir, dst)
|
||||||
certNameHash := "abcdef"
|
certNameHash := "abcdef"
|
||||||
remoteCertHashLink := path.Join(constants.SSLCertStoreDir, fmt.Sprintf("%s.0", certNameHash))
|
remoteCertHashLink := path.Join(SSLCertStoreDir, fmt.Sprintf("%s.0", certNameHash))
|
||||||
cmdMap[fmt.Sprintf("sudo ln -s '%s' '%s'", certFile, certStorePath)] = "1"
|
cmdMap[fmt.Sprintf("sudo ln -s '%s' '%s'", certFile, certStorePath)] = "1"
|
||||||
cmdMap[fmt.Sprintf("openssl x509 -hash -noout -in '%s'", certFile)] = certNameHash
|
cmdMap[fmt.Sprintf("openssl x509 -hash -noout -in '%s'", certFile)] = certNameHash
|
||||||
cmdMap[fmt.Sprintf("sudo ln -s '%s' '%s'", certStorePath, remoteCertHashLink)] = "1"
|
cmdMap[fmt.Sprintf("sudo ln -s '%s' '%s'", certStorePath, remoteCertHashLink)] = "1"
|
||||||
|
|
Loading…
Reference in New Issue