(t *testing.T)
| 22 | ) |
| 23 | |
| 24 | func newTestCA(t *testing.T) *cert.NodeCA { |
| 25 | t.Helper() |
| 26 | dir := t.TempDir() |
| 27 | ca, err := cert.LoadOrCreateNodeCA(filepath.Join(dir, "ca.pem"), filepath.Join(dir, "ca.key")) |
| 28 | if err != nil { |
| 29 | t.Fatalf("create test CA: %v", err) |
| 30 | } |
| 31 | return ca |
| 32 | } |
| 33 | |
| 34 | func newTestCSR(t *testing.T, cn string) string { |
| 35 | t.Helper() |
no test coverage detected