Skip to content

Commit

Permalink
Merge pull request #195 from edx/aht/BOM-2944-replace-travis-with-github
Browse files Browse the repository at this point in the history
BOM-2944: Replace Travis with GitHub CI
  • Loading branch information
UsamaSadiq authored Nov 11, 2021
2 parents ec57280 + d0f1c08 commit 372b658
Show file tree
Hide file tree
Showing 5 changed files with 52 additions and 32 deletions.
48 changes: 48 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
name: Node CI

on:
push:
branches:
- master
pull_request:
branches:
- "**"

jobs:
build:
runs-on: ubuntu-20.04
steps:
- name: Checkout
uses: actions/checkout@v2

- name: Setup Nodejs
uses: actions/setup-node@v2
with:
node-version: 8

- name: Export CHROME_BIN Env Variable
run: export CHROME_BIN=chromium-browser

- name: Export Display Variable
run: export DISPLAY=:99.0

- name: Install Ruby
uses: ruby/setup-ruby@477b21f02be01bcb8030d50f37cfec92bfa615b6
with:
ruby-version: 2.2

- name: Install Dependencies
run: npm install

- name: Bundle Install
run: bundle install

- name: Install Firefox
run: |
sudo apt-get update
sudo apt-get install --no-install-recommends -y firefox xvfb
- name: Run Gulp
uses: GabrielBB/xvfb-action@v1
with:
run: gulp default --ci
1 change: 0 additions & 1 deletion .npmignore
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@

.gitignore
.npmignore
.travis.yml
_config.yml
_preview_site
_site
Expand Down
27 changes: 0 additions & 27 deletions .travis.yml

This file was deleted.

6 changes: 3 additions & 3 deletions test/karma.ci.conf.js
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
var baseConfig = require('./karma.conf');

// Karma configuration to run in Travis
// Karma configuration to run in CI
module.exports = function(config) {
'use strict';

baseConfig(config, {
singleRun: true,
autoWatch: false,
customLaunchers: {
Chrome_travis_ci: {
Chrome_github_ci: {
base: 'Chrome',
flags: ['--no-sandbox']
}
},
browsers: ['Chrome_travis_ci', 'Firefox', 'PhantomJS'],
browsers: ['Chrome_github_ci', 'Firefox', 'PhantomJS'],
logLevel: config.LOG_INFO,
preprocessors: {
'src/js/**/*.js': ['coverage']
Expand Down
2 changes: 1 addition & 1 deletion test/karma.conf.js
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ module.exports = function(config, overrideOptions) {
// enable / disable watching file and executing tests whenever any file changes
autoWatch: options.autoWatch,

// Custom launchers for environments such as Travis
// Custom launchers for environments such as GitHub CI
customLaunchers: options.customLaunchers,

// start these browsers
Expand Down

0 comments on commit 372b658

Please sign in to comment.