top

Debugging and Testing Applications

Published 2014-10-28 |

Introduction to debugging and testing the Smart TV applications with JS Debugger tool provided with SDK and on actual TV.

A key step in application development is debugging and testing on the SDK Emulator and on the TV.

Debugging Applications

Debugging your application enables you to understand its flow of control. Using the JS Debugger tool provided with the SDK, you can set breakpoints, step in, step out, and step over breakpoints, and watch variables to track the changes in their values.

Typically, the debugging process is as follows:

  1. Debug your application with the JS Debugger tool and the emulator. The Emulator gives you execution control over your applications. Note that your application may perform better on an actual TV.
  2. Debug and test with an actual TV.

Once you have finished debugging your application, you can test your application to ensure that it meets your requirements.

Testing Applications

Once you have finished debugging your application, you can run it in one of the following environments:

SDK Emulator
The emulator provided with the SDK simulates running an application on a TV. It enables you to test your application before deploying it to the real TV. Using the emulator allows you to see the results of any code change, thereby enabling incremental development. However, the emulator is not an exact simulation of the TV as it runs on different hardware.
Actual Samsung Smart TV
Running your application on a target device, a Samsung Smart TV, allows you to debug and test your application in a real-time environment. You must run your application on a real TV to be certain of how an application behaves.

The TV environment differs from the computer environment in the following ways:

  • Less memory is available; therefore an application may run out of memory.
  • The response to remote control keys may have a different timing; therefore the responsiveness to user key presses must be separately tested.
  • Only certain remote control keys are allocated to the application.
  • A real TV picture can be seen and the blending of widget graphics over a TV picture can be evaluated.
  • Video and audio playback may behave differently due to use of different hardware.
  • Browser behavior may be different if there are different browser versions in the SDK and in the TV.

Once you have finished debugging and testing, you are ready to package and launch your application.