mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-12-24 17:41:01 +03:00
Adjust logic around log pattern
This is more flexible: the test data gets to decide whether we want to assert the presence of a pattern or not. Signed-off-by: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com>
This commit is contained in:
@@ -5102,9 +5102,7 @@ void inject_client_content_on_the_wire(int pk_alg,
|
||||
ret = mbedtls_ssl_handshake_step(&server.ssl);
|
||||
} while (ret == 0 && server.ssl.state == state);
|
||||
TEST_EQUAL(ret, expected_ret);
|
||||
/* If we're expected to suceeed and we do, that's enough.
|
||||
* If we're expected to fail, also check it was in the expected way. */
|
||||
if (expected_ret != 0) {
|
||||
if (strlen(log_pattern) != 0) {
|
||||
TEST_EQUAL(srv_pattern.counter, 1);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user