Declared inputs and alwaysRunTests find no pytest or Maven tests

Aberta
#271 0 comentários 0 reações 0 responsáveis Ver no GitHub

Mantenedores costumam responder em até 1 dia

@FredApps já está trabalhando nisso.

Desde 17/11/2026.

  • #272 de @FredApps — aberto

Avaliação

Dificuldade
3/5
Tempo estimado
1-2 dias
Facilidade para iniciantes
35/100
Tipo de issue
Bug
Clareza
Claramente especificada
Status de atividade
Estagnada
Stack de tecnologia
typescript
Domínio
ci-cd, testing

Direção de pesquisa

Start in src/repo/impact.ts and trace how knownTestPaths is populated from profile.tests, then how declared input and alwaysRunTests globs select tests. Reproduce with the pytest examples in the issue, then check the Maven case under src/test/java/**. Done means matching pytest and Maven tests are selected for declared inputs and always-run globs; an open linked pull request (#272) is already addressing this issue.

Escrita pelo modelo de indexação a partir do texto da issue.

Descrição

In src/repo/impact.ts, knownTestPaths only collects graph nodes while iterating profile.tests, the JavaScript test locations. pytest and Maven repositories have none, so the list is empty:

  • every declared input in diffci.json fails with "Declared input ... selects no tests; full validation required", even when its tests glob matches real tests;
  • alwaysRunTests globs select nothing, so the listed tests are silently not run.

Repro: pytest repository (testpaths = ["tests"]) with diffci.json {"inputs": [{"files": ["data/model.bin"], "tests": ["tests/test_model.py"]}]}. Change data/model.bin. For the second case, set alwaysRunTests: ["tests/test_smoke.py"] and change any module.

Expected: tests/test_model.py is selected; tests/test_smoke.py is always added.

Actual: full fallback for the declared input; tests/test_smoke.py is missing from the affected tests. Maven (src/test/java/**) behaves the same.

This means the workaround mentioned in #255 falls back rather than selecting tests. Related: #162.

Linguagem predominante
TypeScript
Estrelas
0
Forks
4
Merge médio
18h 41min
PRs com merge (30d)
48

Preparar o ambiente

Abrir no Codespaces

Inicia o contêiner de desenvolvimento do projeto no navegador, com a sua própria conta do GitHub.

Primeiros passos

  1. Leia a issue inteira e depois o guia de contribuição do projeto.
  2. Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
  3. Faça um fork do repositório e trabalhe em uma branch.
  4. Abra um pull request que referencie o número da issue.

Mais de DiffCI/core

Todas as issues de DiffCI/core

Issues semelhantes

Mais issues de TypeScript

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.