From 97a41f532b37f7fd2afdd3837c8b52d425996d25 Mon Sep 17 00:00:00 2001 From: John Safranek Date: Mon, 6 Nov 2023 13:29:03 -0800 Subject: [PATCH] WIP --- tests/api.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/tests/api.c b/tests/api.c index af8510b0f..77fe584a7 100644 --- a/tests/api.c +++ b/tests/api.c @@ -612,7 +612,7 @@ static void test_wolfSSH_ReadKey(void) AssertNotNull(key); AssertIntGT(keySz, 0); AssertStrEQ(keyType, "ssh-rsa"); - AssertIntEQ(keyTypeSz, WSTRLEN("ssh-rsa")); + AssertIntEQ(keyTypeSz, (word32)WSTRLEN("ssh-rsa")); AssertTrue(isPrivate); WFREE(key, NULL, DYNTYPE_FILE); @@ -628,7 +628,7 @@ static void test_wolfSSH_ReadKey(void) AssertNotNull(key); AssertIntGT(keySz, 0); AssertStrEQ(keyType, "ssh-rsa"); - AssertIntEQ(keyTypeSz, WSTRLEN("ssh-rsa")); + AssertIntEQ(keyTypeSz, (word32)WSTRLEN("ssh-rsa")); AssertTrue(isPrivate); WFREE(key, NULL, DYNTYPE_FILE); @@ -644,7 +644,7 @@ static void test_wolfSSH_ReadKey(void) AssertNotNull(key); AssertIntGT(keySz, 0); AssertStrEQ(keyType, "ssh-rsa"); - AssertIntEQ(keyTypeSz, WSTRLEN("ssh-rsa")); + AssertIntEQ(keyTypeSz, (word32)WSTRLEN("ssh-rsa")); AssertFalse(isPrivate); WFREE(key, NULL, DYNTYPE_FILE); @@ -660,7 +660,7 @@ static void test_wolfSSH_ReadKey(void) AssertNotNull(key); AssertIntGT(keySz, 0); AssertStrEQ(keyType, "ecdsa-sha2-nistp256"); - AssertIntEQ(keyTypeSz, WSTRLEN("ecdsa-sha2-nistp256")); + AssertIntEQ(keyTypeSz, (word32)WSTRLEN("ecdsa-sha2-nistp256")); AssertTrue(isPrivate); WFREE(key, NULL, DYNTYPE_FILE); @@ -676,7 +676,7 @@ static void test_wolfSSH_ReadKey(void) AssertNotNull(key); AssertIntGT(keySz, 0); AssertStrEQ(keyType, "ecdsa-sha2-nistp256"); - AssertIntEQ(keyTypeSz, WSTRLEN("ecdsa-sha2-nistp256")); + AssertIntEQ(keyTypeSz, (word32)WSTRLEN("ecdsa-sha2-nistp256")); AssertTrue(isPrivate); WFREE(key, NULL, DYNTYPE_FILE); @@ -692,7 +692,7 @@ static void test_wolfSSH_ReadKey(void) AssertNotNull(key); AssertIntGT(keySz, 0); AssertStrEQ(keyType, "ecdsa-sha2-nistp256"); - AssertIntEQ(keyTypeSz, WSTRLEN("ecdsa-sha2-nistp256")); + AssertIntEQ(keyTypeSz, (word32)WSTRLEN("ecdsa-sha2-nistp256")); AssertFalse(isPrivate); WFREE(key, NULL, DYNTYPE_FILE); @@ -707,10 +707,10 @@ static void test_wolfSSH_ReadKey(void) ret = wolfSSH_ReadKey_file(WOLFSSH_KEYS_PATH "id_rsa", &key, &keySz, &keyType, &keyTypeSz, &isPrivate, NULL); AssertIntEQ(ret, WS_SUCCESS); - AssertPtrEq(key, keyCheck); + AssertNotNull(key); AssertIntGT(keySz, 0); AssertStrEQ(keyType, "ssh-rsa"); - AssertIntEQ(keyTypeSz, WSTRLEN("ssh-rsa")); + AssertIntEQ(keyTypeSz, (word32)WSTRLEN("ssh-rsa")); AssertTrue(isPrivate); WFREE(keyCheck, NULL, DYNTYPE_FILE); }