Fit Recording: Simulator fails with "Permission 'Fit' required" - how to do it right?

In my datafield app (simpledatafield) i'm using a debug label (:test) for a unit test function.

This function, for testing purposes, calls a function in the production code to process test data with it. The production function contains createField calls, to store data in fit files. As specified, this does not work in simulator, because there is no open activity session while codes runs in simulator. Thus, in the test function i create a session. This does not work and fails with a permission error. But permission "FitRecording" is given to the app. If i change it to "Fit" (as stated in the error message) the code does not compile, How can i solve this problem?

Permission 'Fit' required for '$.Toybox.ActivityRecording.createSession'.

Top Replies

All Replies