# SonarCloud's CI-based analysis (.github/workflows/sonarcloud.yml): which # project, what is code, what is test code, and what is not analysed at all. # The scanner reads this file from the commit it analyses, so a pull request # that changes it is analysed with the change. Settings here override the same # settings made in the SonarCloud UI. # https://docs.sonarsource.com/sonarqube-cloud/advanced-setup/analysis-parameters/ # # sonar.sources and sonar.tests take directories. The other keys take path # patterns relative to the repository root, comma-separated: ** is any number # of directories, * any part of a name. sonar.organization=poli0981 sonar.projectKey=poli0981_free-steam-games-list # Tests sit beside the code they test, so both start at the root and the # patterns below split them: a file is a test if it matches # sonar.test.inclusions, and code if it is not excluded. sonar.sources=. sonar.tests=. # pytest, the vitest files, and what only tests and the admin's dev server use # (fakes, fixtures, the mock backend). Analysed with the test rules, and left # out of duplication and coverage. sonar.test.inclusions=scripts/tests/**,**/*.test.ts,web/src/lib/testing/**,web/worker/testing/**,web/admin/mock/** # Excluded from the code: the tests above (they are analysed as tests), and # what is not analysed at all - # - the dataset and the other files the pipeline writes (data/, games/, the # .jsonl queues and logs under scripts/); # - files an analyser cannot read for what they are: the D1 migrations are # SQLite, which the PL/SQL analyser parses as Oracle, and web/src/app.html # is SvelteKit's page template, whose comes in through # %sveltekit.head% (lib/common/Seo.svelte); # - what the Tauri CLI generated and nobody edits: the Android resources, # the Gradle plugin in buildSrc/, and the icon set. The manifest, the # Gradle build files and MainActivity.kt stay in. sonar.exclusions=scripts/tests/**,**/*.test.ts,web/src/lib/testing/**,web/worker/testing/**,web/admin/mock/**,data/**,games/**,**/*.jsonl,**/*.sql,web/src/app.html,web/src-tauri/gen/android/app/src/main/res/**,web/src-tauri/gen/android/buildSrc/**,web/src-tauri/icons/** sonar.sourceEncoding=UTF-8 # Coverage, from the two test runs sonarcloud.yml makes before the scan: # pytest --cov (pyproject.toml's [tool.coverage.run]) and vitest --coverage # (vite.config.ts's test.coverage), both with paths from the repository root. # A file neither report names counts as 0% covered, which is what it is. sonar.python.coverage.reportPaths=coverage.xml sonar.javascript.lcov.reportPaths=web/coverage/lcov.info # Every TypeScript project in web/. Left to itself the analyser finds only # files named exactly tsconfig.json, and analyses the Worker, shared/ and the # tests without their own compiler options. web/tsconfig.json extends the one # `svelte-kit sync` generates, which the workflow runs first (build:admin). sonar.typescript.tsconfigPaths=web/tsconfig.json,web/tsconfig.worker.json,web/tsconfig.test.json,web/admin/tsconfig.json,web/admin/tsconfig.node.json,web/admin/tsconfig.test.json # The version every workflow sets up (actions/setup-python), except CodeQL's, # which stays on the newest Python CodeQL supports. web/shared/toolchain.test.ts # holds them equal. sonar.python.version=3.15