module.exports = {
  ci: {
    collect: {
      staticDistDir: './html',
      settings: {
        // Ajout de --disable-storage-reset et --disable-dev-shm-usage est crucial ici
        chromeFlags: '--no-sandbox --disable-dev-shm-usage --disable-gpu --headless=new --disable-software-rasterizer',
      },
      numberOfRuns: 1
    },
    assert: {
      // On utilise 'preset: lighthouse:recommended' ou on simplifie les assertions
      assertions: {
        'categories:performance': ['warn', {minScore: 0.1}],
        'categories:accessibility': ['warn', {minScore: 0.1}],
        'categories:best-practices': ['warn', {minScore: 0.1}],
        'categories:seo': ['warn', {minScore: 0.1}],
      },
    },
    upload: {
      target: 'filesystem',
      outputDir: './.lighthouseci',
    },
  },
};