[SPARK-4631] unit test for MQTT

Please review the unit test for MQTT
Also try sending a multiple records (10-100 records should be fine).