reconfigure tests environment
This commit is contained in:
62
.github/workflows/CI.yml
vendored
62
.github/workflows/CI.yml
vendored
@@ -89,9 +89,67 @@ jobs:
|
||||
node-modules-
|
||||
- name: Install dependencies
|
||||
run: npm install
|
||||
- name: Install Chrome
|
||||
uses: browser-actions/setup-chrome@latest
|
||||
with:
|
||||
chrome-version: stable
|
||||
- name: Install Chrome dependencies
|
||||
run: |
|
||||
sudo apt-get update
|
||||
sudo apt-get install -y libgbm-dev libasound2t64 libatk1.0-0 libc6 libcairo2 libcups2 libdbus-1-3 libexpat1 libfontconfig1 libgcc1 libgdk-pixbuf2.0-0 libglib2.0-0 libgtk-3-0 libnspr4 libpango-1.0-0 libpangocairo-1.0-0 libstdc++6 libx11-6 libx11-xcb1 libxcb1 libxcomposite1 libxcursor1 libxdamage1 libxext6 libxfixes3 libxi6 libxrandr2 libxrender1 libxss1 libxtst6 libgbm1
|
||||
sudo apt-get install -y \
|
||||
libgbm-dev \
|
||||
libasound2 \
|
||||
libatk1.0-0 \
|
||||
libc6 \
|
||||
libcairo2 \
|
||||
libcups2 \
|
||||
libdbus-1-3 \
|
||||
libexpat1 \
|
||||
libfontconfig1 \
|
||||
libgcc1 \
|
||||
libgdk-pixbuf2.0-0 \
|
||||
libglib2.0-0 \
|
||||
libgtk-3-0 \
|
||||
libnspr4 \
|
||||
libpango-1.0-0 \
|
||||
libpangocairo-1.0-0 \
|
||||
libstdc++6 \
|
||||
libx11-6 \
|
||||
libx11-xcb1 \
|
||||
libxcb1 \
|
||||
libxcomposite1 \
|
||||
libxcursor1 \
|
||||
libxdamage1 \
|
||||
libxext6 \
|
||||
libxfixes3 \
|
||||
libxi6 \
|
||||
libxrandr2 \
|
||||
libxrender1 \
|
||||
libxss1 \
|
||||
libxtst6 \
|
||||
libgbm1
|
||||
- name: Set Chrome flags
|
||||
run: |
|
||||
echo "CHROME_FLAGS=--enable-features=SharedArrayBuffer,CrossOriginIsolation --enable-experimental-web-platform-features --cross-origin-isolated --allow-file-access-from-files --disable-web-security --allow-insecure-localhost --no-sandbox --disable-setuid-sandbox --enable-unsafe-webgpu --disable-gpu-sandbox" >> $GITHUB_ENV
|
||||
- name: Run tests
|
||||
run: npm test
|
||||
env:
|
||||
CHROME_HEADLESS: 1
|
||||
CHROME_PATH: chrome
|
||||
run: |
|
||||
# Start test server with proper headers
|
||||
npm run serve &
|
||||
|
||||
# Wait for server to be ready
|
||||
npx wait-on http://localhost:3000
|
||||
|
||||
# Run tests with configured Chrome flags
|
||||
npx mocha-headless-chrome \
|
||||
--args="$CHROME_FLAGS" \
|
||||
-a no-sandbox \
|
||||
--chrome-path="$(which chrome)" \
|
||||
-f http://localhost:3000/tests/ffmpeg-core-mt.test.html
|
||||
|
||||
# Run remaining tests
|
||||
npm run test:browser:core:st
|
||||
npm run test:browser:ffmpeg:mt
|
||||
npm run test:browser:ffmpeg:st
|
||||
|
||||
Reference in New Issue
Block a user