Index: tst_ui_logs/test.py =================================================================== diff -u -rf561edb90782fefe26b5bc95c2bc46e526241aea -r58d65e5126cac3a1947465c92eeb1abdc7fbcf4c --- tst_ui_logs/test.py (.../test.py) (revision f561edb90782fefe26b5bc95c2bc46e526241aea) +++ tst_ui_logs/test.py (.../test.py) (revision 58d65e5126cac3a1947465c92eeb1abdc7fbcf4c) @@ -32,6 +32,7 @@ from dialin.common.hd_defs import HDOpSubModes, HDOpModes from dialin.common import msg_defs from dialin.utils.conversions import integer_to_bytearray, float_to_bytearray, short_to_bytearray, unsigned_integer_to_bytearray, integer_to_bit_array, unsigned_short_to_bytearray, unsigned_byte_to_bytearray +from symbol import try_stmt hd_simulator = HDSimulator() dg_simulator = DGSimulator() @@ -67,42 +68,8 @@ if param != None: test.verify(param in message_extracted, "parameters are verified") test.endSection() - - -def main(): - utils.tstStart(__file__) - """ - Flag Options: - -h, --help Displays this help. - -v, --version Displays version information. - -c, --canOut Show the Can Frame Output - -m, --msgOut Show the Message Output - -l, --logOut Show the Logs Output - -0, --enable-keep-awake Enable send low priority, empty message - on the CANBus just to keep UI board CAN - driver awake - -i, --fake-interval Test fake message interval(ms) - -f, --fake-message Test fake message data - will use default sequenced long fake - message if set to 00(default) - will used only if correct integer value - assigned for interval option - -b, --fake-message-seq-at-begin Test fake message sequence at the - beginning of the frame - -u, --disable-unhandled-report Disable unhandled messages report as an - error in the log - -d, --disable-dialin-unhandled Disable the Dialin messages logged as - unhandled - -q, --disable-timeout Disables HD communication timeout - -a, --disable-alarm-no-minimize Disables alarm no minimize - -S, --disable-sd-card-fail-log-stop disable-sd-card-fail-log-stop - -k, --enable-check-in-log Enables Check-In Log - -K, --enable-acknow-log Enables Acknowledgment Log - """ - startApplication(config.AUT_NAME+" -d"+ " -i"+ " -f"+ " -b"+ " -u"+ " -c"+ " -0"+ " -m") - - +def verif_ui_logs_api(): #HD Broadcast #0x0D00 hd_simulator.cmd_set_treatment_time(sec_total= 470, sec_elapsed= 300, sec_remain= 170) @@ -1582,6 +1549,67 @@ hd_simulator.cmd_send_hd_general_response(message_id=78, accepted=1, reason=1, is_pure_data=False, has_parameters=True, parameters_payload=payload,channel_id= DenaliChannels.ui_to_hd_ch_id ) hd_simulator.cmd_send_hd_general_response(message_id=78, accepted=0, reason=1, is_pure_data=False, has_parameters=True, parameters_payload=payload,channel_id= DenaliChannels.ui_to_hd_ch_id ) - +def verify_missing_path_verification(): + try: + utility.rename_file(config.CLOUDSYNC_FOLDER_PATH, "cloudsync") + try: + utility.rename_file(config.SD_CARD_CLOUDSYNC_FOLDER_PATH, "cloudsync") + try: + utility.rename_file(config.USB_DISK_FOLDER_LOCATION, "usb-disk") + try: + utility.rename_file(config.APPLICATION_FOLDER_LOCATION, "application") + + utils.waitForGUI(1) + verif_ui_logs_api() + except: + test.log("Error occured while renaming settings files") + except: + test.log("Error occured while renaming canbus files") + except: + test.log("Error occured while renaming scripts files") + except: + test.log("Error occured while renaming application files") + finally: + + utility.rename_old_name(config.APPLICATION_FOLDER_LOCATION, "application") +# utility.rename_old_name(config.SD_CARD_LOCATION, "sd-card") + utility.rename_old_name(config.CLOUDSYNC_FOLDER_PATH, "cloudsync") + utility.rename_old_name(config.SD_CARD_CLOUDSYNC_FOLDER_PATH, "cloudsync") + utility.rename_old_name(config.USB_DISK_FOLDER_LOCATION, "usb-disk") + +def main(): + utils.tstStart(__file__) + """ + Flag Options: + -h, --help Displays this help. + -v, --version Displays version information. + -c, --canOut Show the Can Frame Output + -m, --msgOut Show the Message Output + -l, --logOut Show the Logs Output + -0, --enable-keep-awake Enable send low priority, empty message + on the CANBus just to keep UI board CAN + driver awake + -i, --fake-interval Test fake message interval(ms) + -f, --fake-message Test fake message data + will use default sequenced long fake + message if set to 00(default) + will used only if correct integer value + assigned for interval option + -b, --fake-message-seq-at-begin Test fake message sequence at the + beginning of the frame + -u, --disable-unhandled-report Disable unhandled messages report as an + error in the log + -d, --disable-dialin-unhandled Disable the Dialin messages logged as + unhandled + -q, --disable-timeout Disables HD communication timeout + -a, --disable-alarm-no-minimize Disables alarm no minimize + -S, --disable-sd-card-fail-log-stop disable-sd-card-fail-log-stop + -k, --enable-check-in-log Enables Check-In Log + -K, --enable-acknow-log Enables Acknowledgment Log + """ + + startApplication(config.AUT_NAME+" -d"+ " -i"+ " -f"+ " -b"+ " -u"+ " -c"+ " -0"+ " -m") +# verif_ui_logs_api() + verify_missing_path_verification() utils.tstDone()