Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update the OTA PAL unit tests for 100% code coverage (#1430)
* Add OTA from AFR 202007.00 release * Fix OTA CMake file, add jsmn and tinycbor * Delete JSMN files before submodule * Submodule JSMN on master * Update JSMN to v1.1.0 * Delete tinycbor before submodule * Submodule TinyCBOR to master * Update .gitmodule with the version of TinyCBOR * OTA Agent Posix : Use POSIX thread instead of FreeRTOS task * OTA Agent POSIX: Use POSIX semaphore instead of FreeRTOS semaphore * OTA linux pal * Add OTA demo * Update OTA library to use new MQTT library * OTA LTS Dev: Update include files in OTA Agent File * OTA LTS Dev: Update OTA Agent context initialization * OTA LTS Dev: Self-test timer functions to use timer interface * OTA LTS Dev: Request timer functions implementation to use timers passed to the lib * OTA LTS Dev: use assert instead of configassert in OTA Agent * OTA LTS Dev: Update buffer get and free functions by removing protection * OTA LTS Dev: Add OS interface context to OTA Agent Init functions * OTA LTS Dev: Add OTA OS implementation file * OTA LTS Dev: OTA MQTT demo update * OTA LTS Dev: OTA Agent changes for C-SDK * OTA LTS Dev: OTA MQTT component changes for C-SDK * OTA Dev LTS: OTA OS interface for linux * Add mbedtls * Remove mock * tmp fix for OTA * Remove OTA library * Add OTA as an submodule * Update OTA config with minimum request blocks * Remove ota_os_interface.h from platform folder * Remove stdbool.h from ota_os_posix.h * Update OTA naming convention * Update OTA submodule * Update OTA demo cmake file * Fix warnings * Update OTA submodule * Remove tinycbor from 3rdparty dir * Update OTA submodule and demo CMake file * OTA MQTT demo main and startota functions * MQTT and OS interface in startotademo * OTA MQTT interface publish and subscribe implementation * OTA demo MQTT interface cleanup * Fix OTA demo due to folder structure update * Remove hard coded cert from OTA demo * Use OTA error codes for OTA MQTT interface * Add sending start event from the OTA demo * Implement MQTT unscubscribe function for OTA MQTT * Update OTA submodule and remove jsmn, mbedtls * Update OTA submodule * Update .gitmodules URL and ota target commit * Update OTA submodule * Update OTA submodule and remove iot_appversion32.h * Update naming convention in OTA demo and OTA submodule * Add platform state update in OTA pal for linux * Update OTA demo loop for receivng notification * Update OTA submodule * Update OTA submodule * Add sleep in the OTA demo loop for all conditions * Change to use https link for ota submodule * Add payload size to callback log messages * Remove OTA OS Posix implementation from Paltforms * OTA demo directory change * renaming demos * Refactor MQTT initialization and connection functions * OTA over HTTP demo use local mqtt context * Add http interface to OTA_AgentInit * Add http utils functions * Update HTTP utils functions * OTA over HTTP cmake update for HTTP sources * Implement OTA http request function * Implement http deinit function * Add HTTP port to OTA HTTP demo config * Update OTA submodule * Fix OTA platform cmake file * Remove aws_ota_agent_config.h * Add ota_config.h for MQTT & HTTP demos * change OTA logging to csdk logging in demos * Change OTA logging to Csdk on Linux OTA pal * Update OTA demo config files and OTA submodule * Use application buffers in OTA MQTT demo * Uncrustify demo * use application memory in OTA HTTP * remove ota pal file temporarily * Adding OTA Linux Pal file * Update with new PAL interface * Update after PR review * Update OTA submodule * Refactor and cleanup OTA MQTT demo * Format aws_ota_pal.c * Update log strings in aws_ota_pal.c * Fix typos in aws_ota_pal.c (#47) * Fix space formatting in aws_ota_mqtt.c (#48) * Update OTA submodule * Added OTA Pal unit tests (#50) * ota pal unittests addition * Added more ota pal unittest coverage * Fix file context check in ota linux pal * Update OTA submodule * Formatting changes (#52) * formatting update (#53) * Update OTA submodule * Change OTA demo config and remove pal context checks * Update OTA submodule * Update OTA submodule * Update coreHTTP submodule * Fix OTA HTTP demo * Update Thing Name to 128 * Update ota_config.h * Build and CI checks fixed * Fixing the CMakeLists.txt * Coverity MISRA warning fix * Fix spell check errors * Fix uncrustify warning * changes from review * changes from review * File, folder name changes. * formatting and spell check fix * fix spell check * Update OTA submodule, demo, and posix pal * Update HTTP submodule * Clean up and remove duplicates in demo/lexicon.txt * Fix OTA demo after merge with c-sdk main * Temporarily remove ota demos * Revert a cmake change * Fix some compiler warnings in ota pal posix * Update OTA submodule * Update error codes in OTA pal and unit tests * Add realpath to the file name. (#57) * Add realpath to the file name. * Update OTA submodule * Fix unused variable warning * Fix ota pal unit tests * Remove the private key for ota unit tests * Update CMake files for OTA test mocks * Mock fseek and fwrite in OTA PAL tests * Enhance OTA PAL posix unit test coverage Get 100% coverage for: * otaPal_Abort * otaPal_CreateFileForRx * otaPal_WriteBlock * Fix build errors in posix OTA PAL tests * Mock OpenSSL and stdio func. for OTA unit tests * Rewrite otaPal_GetPlatformImageState unit tests * tmp commit for initial attempt * Add helper function to fail a single mock call * Update unit tests for otaPal_SetPlatformImageState * Add mock helper functions to OTA PAL unit tests * Fix some mistakes in the OTA PAL unit tests * Fix OTA PAL unit test variable names * Get OTA PAL unit test coverage over 90% * Remove some of the alias funcs * Remove impossible condition from OTA PAL * Update OTA PAL unit tests for 100% coverage * Remove unnecessary alias mocks from OTA PAL tests * Organize OTA PAL unit tests * Start to remove global usage * Update OTA PAL unit tests for 100% coverage * Remove globals from OTA PAL unit tests * Uncrustify OTA PAL test files * Fix spelling in OTA PAL unit tests * Fix mistake in OTA PAL unit tests cmake * Add mock header include to OTA PAL test * Fix warnings in OTA PAL unit tests * Fix incorrect OTA PAL test asserts * Fix typos in the lexicon files * Remove unnecessary content from ota.yml * Remove unnecessary OTA PAL unit test. * Clarify variable in OTA PAL unit tests * Remove unnecessary configs from ota.yml * Update spelling and formatting for OTA PAL * Address PR feedback for OTA PAL unit tests * Uncrustify OTA PAL unit test code Co-authored-by: Tiangang Song <[email protected]> Co-authored-by: Prasad Vyawahare <[email protected]> Co-authored-by: Xie <[email protected]> Co-authored-by: xuelix <[email protected]> Co-authored-by: xuelix <[email protected]> Co-authored-by: Shubham Divekar <[email protected]>
- Loading branch information