Skip to content
项目

关于

html5 audio benchmarks

设计与媒体

这些数字如何统计

实测星标增长

24小时
0
7天
0
15天
0
1个月
更新延迟

各周期内的星标净变化,周期相互重叠,并非每日新增。缺失的测量保持空白。星标代表关注度,不代表软件质量。

README.md

原文

Are We Playing Yet?

A pragmatic HTML5 Audio test suite

This is an open and public initiative to bring more harmony into HTML5 Audio implementations. The specifications are missing some features and sometime leaves room for interpretation. We want to un-mute the Web and make Audio rock! If you feel the same, you can report browsers bugs, write tests, fill issues and join our conversation.

ToC

  • Running AWPY
  • Write tests
    • Intro
    • Test structure
    • Terminating tests
  • Submitting issues
    • To browser vendors
    • To AWPY

Running AWPY

You need nodejs and npm.

brew install node
curl http://npmjs.org/install.sh | sh

To prepare the dependencies for the project run the following command in the root of the repository:

npm install

To run the http server invoke the following command:

node server.js

Now you should be able to load http://localhost:3000.

Write tests

Intro

Create a new file in /public/tests
The name should be prefixed by the test type and separated by a hyphen-minus and look like this: type-name
e.g.: event-seeking.js

Miscellaneous tests should be prefixed by "support"

Test structure

A test consists of this basic JSON structure:

({
  name: '', // required (identical to your filename)
  description: '', // required (used as title on the website)
  spec: 'http://…', // optional
  longdesc: 'lorem ipsum…', // optional
  reports: { // optional
    chrome: {
      desc: 'lorem ipsum…',
      link: 'http://…'
    }
  },
  assert: function(finish) { // required
    var audio = this.audio;
  }
})

We encourage you to document it as much as possible by linking to specifications, describing it precisely & including known browser bugs.

Valid values for reports are:

  • firefox
  • opera
  • chrome
  • safari
  • ie
  • firefoxMobile
  • operaMobile
  • android
  • ieMobile
  • safariMobile

Terminating tests

There a 3 ways to terminate a test:

  • passing
  • failing
  • failing by timeout, 15 seconds after loadedmetadata event was triggered

To make a test pass you need to call

finish(true);

To make a test fail call

finish(false);

Submitting issues

To browser vendors

We encourage you to submit issues to browser vendors, here is a list of sites where you can do so for different browsers:

To AWPY

You're very welcome to make suggestions, report issues and open pull requests for changes and new tests.

Before opening a new issue take a second to verify if it doesn't already exist.

If you open a new one, please label it correctly.

Feel free to propose changes to this document.
Happy audio hacking.

探索相关项目

加载中…