mirror of
https://github.com/snapotter-hq/SnapOtter.git
synced 2026-08-03 07:46:42 +02:00
fix: resolve ONNX CUDA fallback, Docker e2e infrastructure, and all test failures
- Add safe_onnx_session() to gpu.py with graceful CUDA EP → CPU fallback - Replace bare ort.InferenceSession() calls across colorize, restore, inpaint, remove_bg - Add libcublas-12-6 to production Dockerfile for ONNX Runtime CUDA EP - Add skipIfFeatureNotInstalled guards to remove-bg, blur-faces, smart-crop, ocr, noise-removal e2e specs - Add AI tool install prompt detection in tools-all.spec.ts - Add smart-crop to PYTHON_SIDECAR_TOOLS so frontend shows install prompt correctly - Create Dockerfile.test.dockerignore to include tests/ in test image builds - Add libheif-examples and exiftool to Dockerfile.test for HEIC and metadata tests - Regenerate visual regression baselines for Docker/Linux and skip on non-Docker platforms
This commit is contained in:
@@ -83,7 +83,7 @@ test.describe("Noise Removal tool", () => {
|
||||
});
|
||||
|
||||
test("GIF + AI tier warning appears and disappears correctly", async ({ loggedInPage: page }) => {
|
||||
await page.goto("/noise-removal");
|
||||
await skipIfFeatureNotInstalled(page);
|
||||
await uploadFile(page, fixturePath("animated.gif"));
|
||||
|
||||
// No warning with balanced tier (default)
|
||||
@@ -102,7 +102,7 @@ test.describe("Noise Removal tool", () => {
|
||||
test("PNG - quick tier removes noise and shows download button", async ({
|
||||
loggedInPage: page,
|
||||
}) => {
|
||||
await page.goto("/noise-removal");
|
||||
await skipIfFeatureNotInstalled(page);
|
||||
await uploadFile(page, fixturePath("test-200x150.png"));
|
||||
|
||||
await page.getByRole("button", { name: "Quick" }).click();
|
||||
@@ -119,7 +119,7 @@ test.describe("Noise Removal tool", () => {
|
||||
test("JPG - balanced tier removes noise and shows download button", async ({
|
||||
loggedInPage: page,
|
||||
}) => {
|
||||
await page.goto("/noise-removal");
|
||||
await skipIfFeatureNotInstalled(page);
|
||||
await uploadFile(page, fixturePath("test-100x100.jpg"));
|
||||
|
||||
// Balanced is default, no need to click it
|
||||
@@ -132,7 +132,7 @@ test.describe("Noise Removal tool", () => {
|
||||
test("WEBP output format - processes and download link is correct type", async ({
|
||||
loggedInPage: page,
|
||||
}) => {
|
||||
await page.goto("/noise-removal");
|
||||
await skipIfFeatureNotInstalled(page);
|
||||
await uploadFile(page, fixturePath("test-200x150.png"));
|
||||
|
||||
await page.getByRole("button", { name: "Quick" }).click();
|
||||
@@ -144,7 +144,7 @@ test.describe("Noise Removal tool", () => {
|
||||
});
|
||||
|
||||
test("download link has correct href after processing", async ({ loggedInPage: page }) => {
|
||||
await page.goto("/noise-removal");
|
||||
await skipIfFeatureNotInstalled(page);
|
||||
await uploadFile(page, fixturePath("test-200x150.png"));
|
||||
|
||||
await page.getByRole("button", { name: "Quick" }).click();
|
||||
|
||||
Reference in New Issue
Block a user