Setting up Roku apps¶
At this point you should have configured Roku in your Suitest account.
.zippackage file extension is supported.
Choosing Roku or Roku Lite¶
By selecting Roku, you will have all the Suitest features at your disposal, however, slower Roku devices or very large applications may suffer performance loss due to Roku device architecture.
Roku Lite has been optimized for slower Roku devices and very large applications, with small limitations (non-essential features) but a significant performance increase.
|Mouse selection tool||✓||-|
|Search by property||✓||✓|
|Suitestify (network requests)||✓||✓|
|Video URL property||✓||-|
To instrument a Roku app you have two choices, either have the library automatically injected into the package or manually insert the Suitest instrumentation code. Then create a build and upload it to Suitest.
Inject the library automatically¶
If you want to use the automated library injection, please make sure that the application has a structure based on the official app creation tutorial. Otherwise, the automated injection may fail.
Suitest can automatically inject the instrumentation library into your application package without your interaction. Select Inject the library automatically before uploading the app package under the App details tab.
If the process fails, please follow the manual instrumentation guide.
If you have already instrumented your app package manually, please do not upload it while having "inject the library automatically" selected.
Inserting instrumentation code manually¶
Our instrumentation library must be inserted into the main scene of the application. In your main scene add the following:
Add a status change observer to initialize our library and to setup an
sub OnSuitestLibStatusChanged(event as object) if event.getData() = "ready" SuitestIL = CreateObject("roSGNode", "SuitestInstrumentationLib:main") SuitestIL.SetField("app_id", "75fc10d1-bf06-4046-8e09-EXAMPLE123") end if end sub
ComponentLibrarywith the instrumentation library URL in the
urifield above your initialization code.
sub init() SuitestLib = CreateObject("roSGNode", "ComponentLibrary") SuitestLib.ObserveField("loadStatus", "OnSuitestLibStatusChanged") SuitestLib.SetField("uri", "http://il.suite.st/app/roku.zip") m.top.InsertChild(SuitestLib, 0) ' ...app init code
Instrumentation library in production
When inserting the instrumentation library you must make sure, that you don't accidentally release the app to production with Suitest code in it. Suitest code is intended for testing and could damage the user experience of your app's users.
Roku Lite solution¶
Roku Lite applications do not need to be instrumented with the Suitest instrumentation library.
Uploading package to Suitest¶
After you have instrumented (not in the case of Roku Lite) the app, create a development build of your app and upload it at the Suitest configuration page. Suitest will automatically install or update the package on the device as necessary when you try running the app on this device.
If you use Suitest Network API you can also send the package with an API request. Suitest will automatically install or update the package on the device as necessary when you try running the app on this device.
Setting up Suitestify¶
- On the application settings page you will need to enable Suitestify by checking the Enable Suitestify checkbox.
- Make sure application domain name is listed in the Suitestify settings. For example, lets assume that the app is hosted at https://example.com therefore the domain added to the domain list is example.com.