Переглянути джерело

Wait before flushing in unit tests

Stéphane Raimbault 14 роки тому
батько
коміт
3c459bc15c
1 змінених файлів з 2 додано та 0 видалено
  1. 2 0
      tests/unit-test-client.c

+ 2 - 0
tests/unit-test-client.c

@@ -600,6 +600,8 @@ int main(int argc, char *argv[])
     /* Restore original timeout */
     modbus_set_timeout_begin(ctx, &timeout_begin_old);
 
+    /* Wait for data before flushing */
+    usleep(100);
     modbus_flush(ctx);
 
     /** BAD RESPONSE **/