tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

ctor-constantsource.html (1410B)


      1 <!DOCTYPE html>
      2 <html>
      3  <head>
      4    <title>
      5      Test Constructor: ConstantSource
      6    </title>
      7    <script src="/resources/testharness.js"></script>
      8    <script src="/resources/testharnessreport.js"></script>
      9    <script src="/webaudio/resources/audit-util.js"></script>
     10    <script src="/webaudio/resources/audit.js"></script>
     11    <script src="/webaudio/resources/audionodeoptions.js"></script>
     12  </head>
     13  <body>
     14    <script id="layout-test-code">
     15      let context;
     16 
     17      let audit = Audit.createTaskRunner();
     18 
     19      audit.define('initialize', (task, should) => {
     20        context = initializeContext(should);
     21        task.done();
     22      });
     23 
     24      audit.define('invalid constructor', (task, should) => {
     25        testInvalidConstructor(should, 'ConstantSourceNode', context);
     26        task.done();
     27      });
     28 
     29      audit.define('default constructor', (task, should) => {
     30        let prefix = 'node0';
     31        let node =
     32            testDefaultConstructor(should, 'ConstantSourceNode', context, {
     33              prefix: prefix,
     34              numberOfInputs: 0,
     35              numberOfOutputs: 1,
     36              channelCount: 2,
     37              channelCountMode: 'max',
     38              channelInterpretation: 'speakers'
     39            });
     40 
     41        testDefaultAttributes(
     42            should, node, prefix, [{name: 'offset', value: 1}]);
     43 
     44        task.done();
     45      });
     46 
     47      audit.run();
     48    </script>
     49  </body>
     50 </html>