smartdevicelink / sdl_javascript_suite

SmartDeviceLink library for applications developed in JavaScript
BSD 3-Clause "New" or "Revised" License
15 stars 13 forks source link

Fix T&G issues with updating state rapidly #555

Closed crokita closed 1 year ago

crokita commented 2 years ago

Fixes #554

Risk

This PR makes no API changes.

Testing Plan

Unit Tests

Add tests for the new _updateTargetStateWithErrorState method

Summary

When sending updates of invalid data followed by valid data to the T&G manager, the valid data will not be thrown out with the invalid data.

Bug Fixes

Resolved an issue with _updatePendingOperationsWithNewScreenData where the wrong identifier was used in the for loop for looping over tasks.

Also fixed _TextAndGraphicUpdateOperation to properly await on sending shows so that the task does not immediately complete.

Fixed variables in test returning undefined due to non-existent SDL.rpc.enums.MetadataType.MEDIA_TITLE value.

theresalech commented 1 year ago

@renonick87 while reviewing, please verify that this check is in place: https://github.com/smartdevicelink/sdl_ios/pull/2107/commits/8180e65affca9258425cef1f016b36768c18c288