Merge remote-tracking branch 'prod-dsi/main'

# Conflicts:
#	server/emailImportService.ts
This commit is contained in:
Manus
2026-08-22 10:39:08 +00:00
5 changed files with 63 additions and 6 deletions

View File

@@ -0,0 +1,45 @@
name: Validation applicative
on:
push:
branches: [main, master]
paths-ignore:
- "**.md"
- "docs/**"
pull_request:
branches: [main, master]
paths-ignore:
- "**.md"
- "docs/**"
workflow_dispatch:
jobs:
verify:
name: TypeScript, tests et build
# Label dédié : image locale avec Node 22, pnpm verrouillé et Bash déjà installés.
runs-on: ci-node22
timeout-minutes: 15
steps:
- name: Récupérer les sources
uses: actions/checkout@v4
- name: Calculer la clé de cache pnpm
id: pnpm-cache-key
shell: bash
run: |
echo "store=$(pnpm store path --silent)" >> "$GITHUB_OUTPUT"
echo "lock=$(sha256sum pnpm-lock.yaml | cut -d ' ' -f 1)" >> "$GITHUB_OUTPUT"
- name: Restaurer le store pnpm
uses: actions/cache@v4
with:
path: ${{ steps.pnpm-cache-key.outputs.store }}
key: pnpm-${{ runner.os }}-${{ steps.pnpm-cache-key.outputs.lock }}
restore-keys: |
pnpm-${{ runner.os }}-
- name: Installer les dépendances verrouillées
run: pnpm install --frozen-lockfile --prefer-offline
- name: Vérifier TypeScript, tests et build
run: pnpm verify

View File

@@ -2,9 +2,15 @@
"id": "demat-facturation-dsi",
"name": "Démat. Facturation DSI",
"category": "SANTINOVA",
"urls": {"recette": "https://demat-facturation.recette.santinova-soft.org", "prod": "https://demat-facturation.santinova-soft.org"},
"urls": {
"recette": "https://demat-facturation.recette.santinova-soft.org",
"prod": "https://demat-facturation.santinova-soft.org"
},
"containerName": "demat-facturation-app",
"image": "images/demat-facturation-dsi.jpg",
"giteaRepo": "demat-facturation-dsi",
"giteaOwner": "manus-admin"
"giteaOwner": "manus-admin",
"ci": {
"required": true
}
}

View File

@@ -10,7 +10,8 @@
"check": "tsc --noEmit",
"format": "prettier --write .",
"test": "vitest run",
"db:push": "drizzle-kit generate && drizzle-kit migrate"
"db:push": "drizzle-kit generate && drizzle-kit migrate",
"verify": "pnpm check && pnpm test && pnpm build"
},
"dependencies": {
"@aws-sdk/client-s3": "^3.693.0",
@@ -137,4 +138,4 @@
"sharp"
]
}
}
}

View File

@@ -427,4 +427,7 @@ async function startServer() {
}, 5000); // Attendre 5s que le serveur soit prêt
}
startServer().catch(console.error);
// Vitest ne doit jamais démarrer un serveur HTTP.
if (!process.env.VITEST) {
startServer().catch(console.error);
}

View File

@@ -1,11 +1,13 @@
import { describe, it, expect, beforeAll } from "vitest";
const describeIntegration = process.env.DATABASE_URL ? describe : describe.skip;
import {
getLlmFieldsConfigByUser,
upsertLlmFieldConfig,
initializeDefaultLlmFields
} from "./db";
describe("LLM Fields Configuration", () => {
describeIntegration("LLM Fields Configuration", () => {
const testUserId = 99999; // Use a high ID to avoid conflicts
beforeAll(async () => {