static const char *pemtype = "PEMTESTDATA";
+static char *pemfile;
+
static int test_b64(int idx)
{
BIO *b = BIO_new(BIO_s_mem());
return 1;
}
+static int test_cert_key_cert(void)
+{
+ EVP_PKEY *key;
+
+ if (!TEST_ptr(key = load_pkey_pem(pemfile, NULL)))
+ return 0;
+
+ EVP_PKEY_free(key);
+ return 1;
+}
+
int setup_tests(void)
{
+ if (!TEST_ptr(pemfile = test_get_argument(0)))
+ return 0;
ADD_ALL_TESTS(test_b64, OSSL_NELEM(b64_pem_data));
ADD_TEST(test_invalid);
+ ADD_TEST(test_cert_key_cert);
return 1;
}