From dc0e887a34b752f61aca772e364e05443a6134a4 Mon Sep 17 00:00:00 2001 From: Nick James Kirkby <20824939+driftregion@users.noreply.github.com> Date: Wed, 24 Jul 2024 20:42:53 +0800 Subject: [PATCH] remove dead code and improve server transport variable name in test_client_0x11_ECU_reset.c --- test/test_client_0x11_ECU_reset.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/test/test_client_0x11_ECU_reset.c b/test/test_client_0x11_ECU_reset.c index 6631df9..731ad07 100644 --- a/test/test_client_0x11_ECU_reset.c +++ b/test/test_client_0x11_ECU_reset.c @@ -35,21 +35,21 @@ int main() { for (size_t i = 0; i < sizeof(p) / sizeof(p[0]); i++) { ENV_CLIENT_INIT(client); - UDSTpHandle_t *srv = ENV_TpNew("server"); + UDSTpHandle_t *srv_tp = ENV_TpNew("server"); // when the client sends a ECU reset request with these options client.options = p[i].options; UDSSendECUReset(&client, kHardReset); // and the server responds with this message - UDSTpSend(srv, p[i].resp, p[i].resp_len, NULL); + UDSTpSend(srv_tp, p[i].resp, p[i].resp_len, NULL); // then the client should receive a response with this error code ENV_RunMillis(50); TEST_INT_EQUAL(client.state, kRequestStateIdle); TEST_INT_EQUAL(client.err, p[i].expected_err); - // assert(client.err == p[i].expected_err); - ENV_TpFree(srv); + + ENV_TpFree(srv_tp); ENV_TpFree(client.tp); } } \ No newline at end of file