C2LC-263: Add feature detection for WebAudio API.

Metadata

Source
C2LC-263
Type
Task
Priority
N/A
Status
Done
Resolution
N/A
Assignee
N/A
Reporter
Created
2020-12-01T05:55:05.987-0500
Updated
2020-12-17T10:14:40.927-0500
Versions
N/A
Fixed Versions
  1. Coding Env 0.6
Component
N/A

Description

As part of C2LC-234, we disabled the rendering tests in App.test.js, which failed because JSDom lacks mocks for the parts of the WebAudio API used by Tone.js.

As we did previously with BlueTooth and Speech Recognition, we can work around this by detecting whether the WebAudio API is available and choosing whether to instantiate the Samplers, Players, et cetera provided by Tone.js.

Comments