tests: Avoid needless skip in testcases

the whole unit is skipped in fips mode

Signed-off-by: Jakub Jelen <jjelen@redhat.com>
Reviewed-by: Pavol Žáčik <pzacik@redhat.com>
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
This commit is contained in:
Jakub Jelen
2026-01-09 18:12:03 +01:00
parent ad8d0c1e03
commit 7dea005729

View File

@@ -190,11 +190,6 @@ static void torture_pki_ed25519_import_pubkey_uri(void **state)
int rc;
struct pki_st *test_state = *state;
/* Skip test if in FIPS mode */
if (ssh_fips_mode()) {
skip();
}
rc = ssh_pki_import_pubkey_file(test_state->pub_uri, &pubkey);
assert_return_code(rc, errno);
@@ -212,11 +207,6 @@ static void torture_pki_ed25519_import_privkey_uri(void **state)
ssh_key privkey = NULL;
struct pki_st *test_state = *state;
/* Skip test if in FIPS mode */
if (ssh_fips_mode()) {
skip();
}
rc = ssh_pki_import_privkey_file(test_state->priv_uri,
NULL,
NULL,
@@ -239,11 +229,6 @@ static void torture_pki_sign_verify_uri(void **state)
ssh_session session = ssh_new();
struct pki_st *test_state = *state;
/* Skip test if in FIPS mode */
if (ssh_fips_mode()) {
skip();
}
rc = ssh_pki_import_privkey_file(test_state->priv_uri,
NULL,
NULL,
@@ -276,11 +261,6 @@ static void torture_pki_ed25519_publickey_from_privatekey_uri(void **state)
ssh_key pubkey = NULL;
struct pki_st *test_state = *state;
/* Skip test if in FIPS mode */
if (ssh_fips_mode()) {
skip();
}
rc = ssh_pki_import_privkey_file(test_state->priv_uri,
NULL,
NULL,
@@ -308,11 +288,6 @@ static void torture_pki_ed25519_uri_invalid_configurations(void **state)
struct pki_st *test_state = *state;
/* Skip test if in FIPS mode */
if (ssh_fips_mode()) {
skip();
}
rc = ssh_pki_import_pubkey_file(test_state->pub_uri_invalid_object, &pubkey);
assert_int_not_equal(rc, 0);
assert_null(pubkey);