Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions .github/workflows/nodejs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,19 @@ jobs:
uses: actions/setup-node@v1
with:
node-version: 18.x
- name: Set CHROME_BIN (macOS)
if: startsWith(matrix.os, 'macos')
run: echo "CHROME_BIN=/Applications/Google Chrome.app/Contents/MacOS/Google Chrome" >> $GITHUB_ENV
- name: Install Chromium runtime deps (Linux)
if: startsWith(matrix.os, 'ubuntu')
run: |
sudo apt-get update
common="libxkbcommon0 libgbm1 libxcomposite1 libxdamage1 libxfixes3 libxrandr2 libnss3 libnspr4 libx11-6 libx11-xcb1 libxext6 libxshmfence1 libdrm2"
if apt-cache show libatk1.0-0 >/dev/null 2>&1; then
sudo apt-get install -y libatk1.0-0 libatk-bridge2.0-0 libcups2 libasound2 libatspi2.0-0 libglib2.0-0 libgtk-3-0 $common
else
sudo apt-get install -y libatk1.0-0t64 libatk-bridge2.0-0t64 libcups2t64 libasound2t64 libatspi2.0-0t64 libglib2.0-0t64 libgtk-3-0t64 $common
fi
- name: npm install, build, and test
run: |
npm install
Expand Down
18 changes: 18 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,15 @@ jobs:
node-version: 18
registry-url: https://registry.npmjs.org/
cache: npm
- name: Install Chromium runtime deps (Linux)
run: |
sudo apt-get update
common="libxkbcommon0 libgbm1 libxcomposite1 libxdamage1 libxfixes3 libxrandr2 libnss3 libnspr4 libx11-6 libx11-xcb1 libxext6 libxshmfence1 libdrm2"
if apt-cache show libatk1.0-0 >/dev/null 2>&1; then
sudo apt-get install -y libatk1.0-0 libatk-bridge2.0-0 libcups2 libasound2 libatspi2.0-0 libglib2.0-0 libgtk-3-0 $common
else
sudo apt-get install -y libatk1.0-0t64 libatk-bridge2.0-0t64 libcups2t64 libasound2t64 libatspi2.0-0t64 libglib2.0-0t64 libgtk-3-0t64 $common
fi
- run: npm ci
- run: npm test
- run: npm version ${TAG_NAME} --git-tag-version=false
Expand All @@ -42,6 +51,15 @@ jobs:
registry-url: https://npm.pkg.github.com
cache: npm
scope: '@github'
- name: Install Chromium runtime deps (Linux)
run: |
sudo apt-get update
common="libxkbcommon0 libgbm1 libxcomposite1 libxdamage1 libxfixes3 libxrandr2 libnss3 libnspr4 libx11-6 libx11-xcb1 libxext6 libxshmfence1 libdrm2"
if apt-cache show libatk1.0-0 >/dev/null 2>&1; then
sudo apt-get install -y libatk1.0-0 libatk-bridge2.0-0 libcups2 libasound2 libatspi2.0-0 libglib2.0-0 libgtk-3-0 $common
else
sudo apt-get install -y libatk1.0-0t64 libatk-bridge2.0-0t64 libcups2t64 libasound2t64 libatspi2.0-0t64 libglib2.0-0t64 libgtk-3-0t64 $common
fi
- run: npm ci
- run: npm test
- run: npm version ${TAG_NAME} --git-tag-version=false
Expand Down
10 changes: 8 additions & 2 deletions karma.config.cjs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
process.env.CHROME_BIN = require('chromium').path
process.env.CHROME_BIN = process.env.CHROME_BIN || require('chromium').path

module.exports = function(config) {
config.set({
Expand All @@ -11,7 +11,13 @@ module.exports = function(config) {
port: 9876,
colors: true,
logLevel: config.LOG_INFO,
browsers: ['ChromeHeadless'],
customLaunchers: {
ChromeHeadlessNoSandbox: {
base: 'ChromeHeadless',
flags: ['--no-sandbox', '--disable-setuid-sandbox'],
},
},
browsers: ['ChromeHeadlessNoSandbox'],
autoWatch: false,
singleRun: true,
concurrency: Infinity
Expand Down
13 changes: 7 additions & 6 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading