* Verifies that the method spy's are in the right state for a controller * that has been injected. * * @param {object} component - The oculus-go-controls component to verify fields.
(component)
| 47 | * @param {object} component - The oculus-go-controls component to verify fields. |
| 48 | */ |
| 49 | function verifyControllerSetup (component) { |
| 50 | sinon.assert.calledOnce(injectTrackedControlsSpy); |
| 51 | sinon.assert.calledOnce(addEventListenersSpy); |
| 52 | sinon.assert.notCalled(removeEventListenersSpy); |
| 53 | assert.strictEqual(component.controllerPresent, true); |
| 54 | } |
| 55 | |
| 56 | test('returns not present if no controllers on first call', function () { |
| 57 | // Our current setup state is that no controllers are present. Check for presence |
no outgoing calls
no test coverage detected