@@ -95,57 +95,39 @@ jobs:
9595          chrome-version : stable 
9696        env :
9797          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" 
98-       - name : Install Chrome dependencies 
99-         run : | 
100-           sudo apt-get update 
101-           sudo apt-get install -y \ 
102-             libgbm-dev \ 
103-             libasound2t64 \ 
104-             libatk1.0-0 \ 
105-             libc6 \ 
106-             libcairo2 \ 
107-             libcups2 \ 
108-             libdbus-1-3 \ 
109-             libexpat1 \ 
110-             libfontconfig1 \ 
111-             libgcc1 \ 
112-             libgdk-pixbuf2.0-0 \ 
113-             libglib2.0-0 \ 
114-             libgtk-3-0 \ 
115-             libnspr4 \ 
116-             libpango-1.0-0 \ 
117-             libpangocairo-1.0-0 \ 
118-             libstdc++6 \ 
119-             libx11-6 \ 
120-             libx11-xcb1 \ 
121-             libxcb1 \ 
122-             libxcomposite1 \ 
123-             libxcursor1 \ 
124-             libxdamage1 \ 
125-             libxext6 \ 
126-             libxfixes3 \ 
127-             libxi6 \ 
128-             libxrandr2 \ 
129-             libxrender1 \ 
130-             libxss1 \ 
131-             libxtst6 \ 
132-             libgbm1 
13398      - name : Run tests 
13499        env :
135100          CHROME_HEADLESS : 1 
136101          CHROME_PATH : chrome 
102+           HEADERS : ' {"Cross-Origin-Opener-Policy": "same-origin", "Cross-Origin-Embedder-Policy": "require-corp"}' 
137103        run : | 
138-           # Start test server with proper headers 
139-           npm run serve -- --headers '{"Cross-Origin-Opener-Policy": "same-origin", "Cross-Origin-Embedder-Policy": "require-corp"}' & 
104+           # Start test server with proper headers for all tests 
105+           npm run serve -- --headers "$HEADERS" & 
106+ 
107+           # Wait for server to start 
108+           sleep 5 
140109
141-           # Run tests with configured Chrome flags  
110+           # Run all  tests with proper headers  
142111          npx mocha-headless-chrome \ 
143112            --args="$CHROME_FLAGS" \ 
144113            -a no-sandbox \ 
145114            --chrome-path="$(which chrome)" \ 
146115            -f http://localhost:3000/tests/ffmpeg-core-mt.test.html 
147116
148-           # Run remaining tests 
149-           npm run test:browser:core:st 
150-           npm run test:browser:ffmpeg:mt 
151-           npm run test:browser:ffmpeg:st 
117+           npx mocha-headless-chrome \ 
118+             --args="$CHROME_FLAGS" \ 
119+             -a no-sandbox \ 
120+             --chrome-path="$(which chrome)" \ 
121+             -f http://localhost:3000/tests/ffmpeg-core-st.test.html 
122+ 
123+           npx mocha-headless-chrome \ 
124+             --args="$CHROME_FLAGS" \ 
125+             -a no-sandbox \ 
126+             --chrome-path="$(which chrome)" \ 
127+             -f http://localhost:3000/tests/ffmpeg-mt.test.html 
128+ 
129+           npx mocha-headless-chrome \ 
130+             --args="$CHROME_FLAGS" \ 
131+             -a no-sandbox \ 
132+             --chrome-path="$(which chrome)" \ 
133+             -f http://localhost:3000/tests/ffmpeg-st.test.html 
0 commit comments