add headers
This commit is contained in:
		
							parent
							
								
									58fccc8548
								
							
						
					
					
						commit
						43d30bfe71
					
				
							
								
								
									
										2
									
								
								.github/workflows/CI.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										2
									
								
								.github/workflows/CI.yml
									
									
									
									
										vendored
									
									
								
							@ -101,7 +101,7 @@ jobs:
 | 
			
		||||
          HEADERS: '{"Cross-Origin-Opener-Policy": "same-origin", "Cross-Origin-Embedder-Policy": "require-corp", "Cross-Origin-Resource-Policy": "cross-origin", "Origin-Agent-Cluster": "?1"}'
 | 
			
		||||
        run: |
 | 
			
		||||
          # Start test server with proper headers for all tests
 | 
			
		||||
          npm run serve &
 | 
			
		||||
          npm run serve -- --headers "$HEADERS" &
 | 
			
		||||
 | 
			
		||||
          # Wait for server to start and ensure headers are properly set
 | 
			
		||||
          sleep 10
 | 
			
		||||
 | 
			
		||||
@ -8,6 +8,7 @@ const ROOT = path.join(__dirname, "public");
 | 
			
		||||
app.use((_, res, next) => {
 | 
			
		||||
  res.append("Cross-Origin-Opener-Policy", "same-origin");
 | 
			
		||||
  res.append("Cross-Origin-Embedder-Policy", "require-corp");
 | 
			
		||||
  res.append("Cross-Origin-Resource-Policy", "cross-origin");
 | 
			
		||||
  next();
 | 
			
		||||
});
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
@ -1,3 +1,14 @@
 | 
			
		||||
const isMTSupported = typeof SharedArrayBuffer !== "undefined";
 | 
			
		||||
const isIsolated = window.crossOriginIsolated;
 | 
			
		||||
 | 
			
		||||
if (FFMPEG_TYPE === "mt" && !isMTSupported) {
 | 
			
		||||
  console.warn("SharedArrayBuffer not available, skipping MT tests");
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
if (FFMPEG_TYPE === "mt" && !isIsolated) {
 | 
			
		||||
  console.warn("Cross-origin isolation not available, skipping MT tests");
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
let core;
 | 
			
		||||
 | 
			
		||||
const genName = (name) => `[ffmpeg-core][${FFMPEG_TYPE}] ${name}`;
 | 
			
		||||
 | 
			
		||||
		Loading…
	
		Reference in New Issue
	
	Block a user