mirror of
https://github.com/scratchfoundation/scratch-audio.git
synced 2024-12-22 22:12:48 -05:00
18 lines
443 B
JavaScript
18 lines
443 B
JavaScript
|
const tap = require('tap');
|
||
|
const AudioEngine = require('../src/AudioEngine');
|
||
|
|
||
|
const {AudioContext} = require('web-audio-test-api');
|
||
|
|
||
|
tap.test('AudioEngine', t => {
|
||
|
const audioEngine = new AudioEngine(new AudioContext());
|
||
|
|
||
|
t.deepEqual(audioEngine.inputNode.toJSON(), {
|
||
|
gain: {
|
||
|
inputs: [],
|
||
|
value: 1
|
||
|
},
|
||
|
inputs: [],
|
||
|
name: 'GainNode'
|
||
|
}, 'JSON Representation of inputNode');
|
||
|
});
|