@@ -71,13 +71,13 @@ static void test_send_characters(int socket_fd, const char *msg)
7171 TEST_ASSERT_EQUAL (msg_len , nwrite );
7272}
7373
74- esp_err_t test_pre_executor (void * ctx , char * buf , const esp_err_t reader_ret_val )
74+ esp_err_t test_pre_executor (void * ctx , const char * buf , esp_err_t reader_ret_val )
7575{
7676 s_pre_executor_nb_of_calls ++ ;
7777 return ESP_OK ;
7878}
7979
80- esp_err_t test_post_executor (void * ctx , const char * buf , const esp_err_t executor_ret_val , const int cmd_ret_val )
80+ esp_err_t test_post_executor (void * ctx , const char * buf , esp_err_t executor_ret_val , int cmd_ret_val )
8181{
8282 s_post_executor_nb_of_calls ++ ;
8383 return ESP_OK ;
@@ -222,14 +222,6 @@ TEST_CASE("esp_repl() loop calls all callbacks and exit on call to esp_repl_stop
222222 test_socket_teardown (s_socket_fd );
223223}
224224
225- static int quit_command (void * context , const int fd_out , int argc , char * * argv )
226- {
227- esp_repl_handle_t repl_handle = (esp_repl_handle_t )context ;
228- TEST_ASSERT_EQUAL (ESP_OK , esp_repl_stop (repl_handle ));
229-
230- return 0 ;
231- }
232-
233225TEST_CASE ("esp_repl() exits when esp_repl_stop() called from the task running esp_repl()" , "[esp_repl]" )
234226{
235227 /* create semaphores */
@@ -274,18 +266,6 @@ TEST_CASE("esp_repl() exits when esp_repl_stop() called from the task running es
274266 BaseType_t rc = xTaskCreate (repl_task , "repl_task" , 4096 , & args , 5 , NULL );
275267 TEST_ASSERT_EQUAL (pdPASS , rc );
276268
277- /* register a quit command to esp_commands */
278- esp_command_t quit_cmd = {
279- .name = "quit" ,
280- .group = "quit" ,
281- .help = "-" ,
282- .func = quit_command ,
283- .func_ctx = repl_handle ,
284- .hint_cb = NULL ,
285- .glossary_cb = NULL
286- };
287- TEST_ASSERT_EQUAL (ESP_OK , esp_commands_register_cmd (& quit_cmd ));
288-
289269 /* start repl */
290270 TEST_ASSERT_EQUAL (ESP_OK , esp_repl_start (repl_handle ));
291271
@@ -295,7 +275,7 @@ TEST_CASE("esp_repl() exits when esp_repl_stop() called from the task running es
295275 TEST_ASSERT_TRUE (xSemaphoreTake (start_sem , pdMS_TO_TICKS (2000 )));
296276
297277 /* send the quit command */
298- const char * quit_cmd_line = "quit\n" ;
278+ const char * quit_cmd_line = "quit \n" ;
299279 test_send_characters (s_socket_fd [1 ], quit_cmd_line );
300280
301281 /* wait for the repl task to signal completion */
0 commit comments