Skip to contentSkip to conversation

testsuite/smokey: net_client: skip late packet error in vm mode

PATCH New Hongzhan Chen 1 participant 1 message Aug 6, 2021

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 testsuite/smokey: net_client: skip late packet error in vm mode

In vm mode, skip late packet error in functional test to avoid test failure.

---
 testsuite/smokey/net_common/client.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
testsuite/smokey/net_common/client.c +2 -2
index d13d72918..02a9e7e6d 100644
@@ -204,7 +204,7 @@ static int smokey_net_client_loop(struct smokey_net_client *client)
 		} while (err != -ETIMEDOUT);
 	}
 
-	if (glost || glate)
+	if (glost || (!smokey_on_vm && glate))
 		fprintf(stderr, "RTnet %s test failed", client->name);
 	if (glost) {
 		if (glost == limit)
@@ -218,7 +218,7 @@ static int smokey_net_client_loop(struct smokey_net_client *client)
 		fprintf(stderr, ", %Lu overruns", glate);
 	if (glost || glate)
 		fputc('\n', stderr);
-	err = glost || glate ? -EPROTO : 0;
+	err = glost || (!smokey_on_vm && glate) ? -EPROTO : 0;
 
   err:
 	sock = smokey_check_errno(__RT(close(sock)));
Signature · 1 line
2.17.1