(t *testing.T)
| 864 | } |
| 865 | |
| 866 | func TestCACertBundleInvalidPath(t *testing.T) { |
| 867 | cfg := Github{ |
| 868 | Name: "dummy_creds", |
| 869 | Description: "dummy github credentials", |
| 870 | OAuth2Token: "bogus", |
| 871 | CACertBundlePath: "/i/dont/exist", |
| 872 | } |
| 873 | |
| 874 | cert, err := cfg.CACertBundle() |
| 875 | require.NotNil(t, err) |
| 876 | require.EqualError(t, err, "error accessing ca_cert_bundle: stat /i/dont/exist: no such file or directory") |
| 877 | require.Nil(t, cert) |
| 878 | } |
| 879 | |
| 880 | func TestCACertBundleInvalidFile(t *testing.T) { |
| 881 | cfg := Github{ |
nothing calls this directly
no test coverage detected