A test project passes with zero tests, and the CI shards are listed by hand

Aperta
#3,311 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
45/100
Tipo di issue
Funzionalità
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
csharp, github-actions, postgresql

Direzione di ricerca

Start with Directory.Build.props:73-76, .github/workflows/ci.yml:90-106, DatabaseServer.cs:90, and SqlServerPool.cs:32-45 to trace the test settings, shard coverage, and existing database template approach. Check how the solution discovers test projects and how PostgreSQL tests create and migrate databases. Done means empty test projects fail, every test project is covered by a shard, and PostgreSQL tests migrate once per run; record the time saved in the pull request. Coordinate with #3267, which changes the same workflow.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

area:build area:testing type:bug

Problem

  1. A test project passes when it runs no tests. Directory.Build.props:73-76 sets --ignore-exit-code 8 for every project under tests/, with a comment about stubs that no longer applies. Filtered runs are guarded by --minimum-expected-tests; the unfiltered shards (.github/workflows/ci.yml:90,101-106) are not.
  2. The shard lists are maintained by hand. ci.yml:90-106 names each test project. A new one runs on no pull request and no push to main; only the nightly Windows run picks it up.
  3. PostgreSQL tests create and migrate a database per test. DatabaseServer.cs:90 runs CREATE DATABASE for each test, and each test migrates it. SQL Server already clones a migrated template (SqlServerPool.cs:32-45).

Proposal

  • Remove the ignored exit code.
  • A check that every test project of the solution is in a shard.
  • Migrate one template database per run and create test databases from it.

Done together with #3267, which changes the same workflow.

Acceptance

  • A test project that discovers no tests fails the run
  • A test project missing from the shards fails CI
  • PostgreSQL tests no longer migrate per test; the time saved is noted in the pull request

Found in the code review of 17 Nov 2026.

Lingua principale
C#
Stelle
569
Fork
107
Merge medio
2h 49m
PR unite (30g)
397

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di fluentcms/FluentCMS

Tutte le issue di fluentcms/FluentCMS

Issue simili

Altre issue su C#

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.