Maven: follow a custom `<testSourceDirectory>`

Offen
#163 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Maintainer antworten meist innerhalb von 1 Tag

Dieses Issue hat noch niemand übernommen.

Bewertung

Schwierigkeit
3/5
Geschätzter Aufwand
1-2 Tage
Anfängerfreundlichkeit
68/100
Issue-Typ
Feature
Klarheit
Klar beschrieben
Aktivitätsstatus
Aktiv
Tech-Stack
typescript

Rechercherichtung

Start in src/repo/adapters/maven.ts and inspect how custom source roots trigger the full-validation blocker. Find the Maven adapter tests and synthetic fixtures under tests/repo/, then add cases for a resolvable custom test root, a custom source root, and an unresolved or outside-module test root. Run npm test; done means only the resolvable test-root case avoids fallback, while the other two still fall back for the stated reason.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Beschreibung

adapter help wanted

Part of #89 (the "Follow custom <sourceDirectory> and <testSourceDirectory> roots" step), split out so it can be done on its own.

Today any custom source root makes the Maven adapter fall back to the full suite: src/repo/adapters/maven.ts sets customSourceRoots when a POM's <sourceDirectory> isn't src/main/java or its <testSourceDirectory> isn't src/test/java, and that adds the blocker Maven <pom>: custom source roots require full validation.

The test root alone is the smaller half: it only changes where tests are found, not how modules depend on each other.

Done when:

  • A module whose only customization is <testSourceDirectory> finds its tests there and no longer falls back for that reason.
  • A custom <sourceDirectory> still falls back, with the same reason as today.
  • A <testSourceDirectory> the adapter can't resolve with certainty (a property such as ${project.basedir}/..., or a path outside the module) still falls back. Never guess.
  • There are synthetic Maven fixtures under tests/repo/ for each case above.

maven.ts is 128 lines. This is a step up from a good first issue: it suits someone who has already merged a PR or two here.


See CONTRIBUTING.md: add a synthetic fixture, run npm test, and sign off commits with git commit -s. Comment here to claim the issue.

Vorherrschende Sprache
TypeScript
Sterne
0
Forks
4
Ø Merge
18 Std. 41 Min.
Gemergte PRs (30 T.)
48

Entwicklungsumgebung

In Codespaces öffnen

Startet den Dev-Container des Projekts im Browser, mit Ihrem eigenen GitHub-Konto.

Erste Schritte

  1. Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
  3. Forken Sie das Repository und arbeiten Sie in einem Branch.
  4. Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.

Mehr aus DiffCI/core

Alle Issues in DiffCI/core

Ähnliche Issues

Weitere Issues zu TypeScript

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.