-
Notifications
You must be signed in to change notification settings - Fork 69
Testing with JSARToolKit with Qunit
JSARToolKit can be tested using the integrated Unit tests. These tests are written using the QUnit testing framework. All tests are located in ./tests
. The tests consist of one index.html page that uses the tests.js which in turn contains all the tests.
The tests check the functionality of the ARCameraParam
, ARController
, ARController.getUserMedia
, ARController.getUserMediaARController
.
They should be run using https because they access the camera stream from the browser which should use an https connection. In fact, only Firefox allows accessing the camera stream from an HTTP connection Chrome and Safari won't open the camera stream on an HTTP connection.
To setup https on your local machine, you can follow the guide [here] (https://github.com/artoolkitx/jsartoolkit5/blob/master/startServer-https.md)
The tests can then be run accessing https://localhost:8085/tests/index.html
.
- All test work on Android Chrome version 63.0.3239.111
- On Android Firefox 57.0.4 test 10 fails because of switched video resolution
- On iOS only Safari allows access to the video (as of 2018-01-08). Also Safari does not seem to allow the opening and closing of the camera multiple times within a short time frame. Because of that the tests 10+ fail.
- Chrome (Version 63.0.3239.108 and Version 63.0.3239.132) on desktop all tests work.
- Firefox (Version 57.0.1 and 57.0.4) on desktop all tests work.
- Safari (Version 11.0.2) on desktop all tests work