Skip to content

Commit a4be9fa

Browse files
author
Oliva Kar
committed
updated test
1 parent a19973c commit a4be9fa

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

device/tests/iothub_client_e2e.py

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
import threading
1212
import types
1313
import base64
14+
import time
1415

1516
from iothub_service_client import IoTHubRegistryManager, IoTHubRegistryManagerAuthMethod
1617
from iothub_service_client import IoTHubMessaging
@@ -546,6 +547,18 @@ def run_e2e_device_client(iothub_service_client_messaging, iothub_device_method,
546547

547548
# verify
548549
assert MESSAGE_RECEIVE_CALLBACK_COUNTER > 0, "Error: message has not been received"
550+
551+
# prepare
552+
MESSAGING_MESSAGE = ""
553+
empty_message = IoTHubMessage(MESSAGING_MESSAGE)
554+
# act
555+
sc_send_message(iothub_service_client_messaging, device_id, empty_message, testing_modules)
556+
time.sleep(60)
557+
MESSAGE_RECEIVE_EVENT.wait(CALLBACK_TIMEOUT)
558+
559+
# verify
560+
assert MESSAGE_RECEIVE_CALLBACK_COUNTER > 1, "Error: empty message has not been received"
561+
549562
###########################################################################
550563

551564
###########################################################################

0 commit comments

Comments
 (0)