Skip to content

Commit

Permalink
Merge a36ad5e into 12ff539
Browse files Browse the repository at this point in the history
  • Loading branch information
thijstriemstra committed Apr 25, 2018
2 parents 12ff539 + a36ad5e commit 8c7381f
Show file tree
Hide file tree
Showing 13 changed files with 351 additions and 689 deletions.
8 changes: 3 additions & 5 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,13 @@
sudo: false
dist: trusty
addons:
chrome: stable
language: node_js
node_js:
- 'node'
before_install:
- export CHROME_BIN=chromium-browser
- export DISPLAY=:99.0
- sh -e /etc/init.d/xvfb start
install:
- npm prune
- npm install
- npm update
script:
- npm run lint
- npm run build
Expand Down
8 changes: 8 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,14 @@
videojs-wavesurfer changelog
============================

2.3.1 - unreleased
------------------

- Make sure plugin is only registered once
- Add `isDestroyed` method
- Add more tests


2.3.0 - 2018/04/16
------------------

Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ input](#microphone-plugin).
[![npm](https://img.shields.io/npm/dm/videojs-wavesurfer.svg)](https://github.com/collab-project/videojs-wavesurfer/releases)
[![License](https://img.shields.io/npm/l/videojs-wavesurfer.svg)](LICENSE)
[![Build Status](https://travis-ci.org/collab-project/videojs-wavesurfer.svg?branch=master)](https://travis-ci.org/collab-project/videojs-wavesurfer)
[![Coverage Status](https://coveralls.io/repos/github/collab-project/videojs-wavesurfer/badge.svg?branch=master)](https://coveralls.io/github/collab-project/videojs-wavesurfer?branch=master)

Installation
------------
Expand Down
8 changes: 7 additions & 1 deletion appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,25 @@ environment:
matrix:
- nodejs_version: '8'
install:
- choco install -y googlechrome --ignore-checksums
- ps: Install-Product node $env:nodejs_version
- set CI=true
- npm install --global npm@latest
- set PATH=%APPDATA%\npm;%PATH%
- npm install
matrix:
fast_finish: true
# Disable automatic builds
build: off
# Do not build on gh tags
skip_tags: true
shallow_clone: true
test_script:
- node --version
- npm --version
- npm run test
- npm run lint
- npm run build
- npm run test
cache:
- '%APPDATA%\npm-cache'
- node_modules -> package.json
44 changes: 36 additions & 8 deletions karma.conf.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,18 @@ require('babel-register');

var webpackConfig = require('./build-config/webpack.prod.main.js');

var chromeFlags = [
'--no-sandbox',
'--use-fake-device-for-media-stream',
'--use-fake-ui-for-media-stream',
'--use-file-for-fake-audio-capture=test/support/demo.wav',
'--autoplay-policy=no-user-gesture-required'
];
var firefoxFlags = {
'media.navigator.permission.disabled': true,
'media.navigator.streams.fake': true
};

module.exports = function(config) {
var configuration = {
basePath: '',
Expand All @@ -27,11 +39,11 @@ module.exports = function(config) {
},

// style
'node_modules/video.js/dist/video-js.css',
'dist/css/videojs.wavesurfer.css',

// dependencies
'node_modules/video.js/dist/video.js',
'node_modules/video.js/dist/video-js.css',
'node_modules/wavesurfer.js/dist/wavesurfer.js',
'node_modules/wavesurfer.js/dist/plugin/wavesurfer.microphone.js',

Expand All @@ -53,10 +65,12 @@ module.exports = function(config) {
'karma-jasmine',
'karma-jasmine-matchers',
'karma-chrome-launcher',
'karma-firefox-launcher',
'karma-coverage',
'karma-coveralls',
'karma-verbose-reporter'
],
browsers: ['ChromeHeadless'],
browsers: ['Firefox_dev', 'Chrome_dev'],
captureConsole: true,
colors: true,
reporters: ['verbose', 'progress', 'coverage'],
Expand All @@ -66,17 +80,31 @@ module.exports = function(config) {
},
webpack: webpackConfig,
customLaunchers: {
Chrome_travis_ci: {
Chrome_dev: {
base: 'Chrome',
flags: [
'--no-sandbox'
]
flags: chromeFlags
},
Chrome_ci: {
base: 'ChromeHeadless',
flags: chromeFlags
},
Firefox_dev: {
base: 'Firefox',
prefs: firefoxFlags
}
}
};

if (process.env.TRAVIS) {
configuration.browsers = ['Chrome_travis_ci'];
if (process.env.TRAVIS || process.env.APPVEYOR) {
configuration.browsers = ['Chrome_ci'];
configuration.singleRun = true;

if (process.env.TRAVIS) {
// enable coveralls
configuration.reporters.push('coveralls');
// lcov or lcovonly are required for generating lcov.info files
configuration.coverageReporter.type = 'lcov';
}
}

config.set(configuration);
Expand Down

0 comments on commit 8c7381f

Please sign in to comment.