Skip to content

Commit 7e0ac76

Browse files
dnguy078claude
andcommitted
Avoid typeshed-dependent file count in daemon regression test
The "checked N source files" summary line varies with the bundled typeshed version, which would make the test fail spuriously after a typeshed sync. Start the daemon with --no-error-summary so the test asserts only on the diagnostics that the fix actually affects. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
1 parent 5b0cd60 commit 7e0ac76

1 file changed

Lines changed: 3 additions & 4 deletions

File tree

test-data/unit/daemon.test

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -804,19 +804,18 @@ from xml.etree.ElementTree import Element
804804
1 + 'a'
805805

806806
[case testDaemonRecheckMissingGraphDependency]
807-
$ dmypy start
807+
-- Dropping pkg.tests from the graph leaves a stale ancestors edge behind, which
808+
-- a later recheck used to dereference unconditionally (KeyError: 'pkg.tests').
809+
$ dmypy start -- --no-error-summary
808810
Daemon started
809811
$ dmypy check src/
810812
src/pkg/example.py:2: error: Name "x" already defined on line 1 [no-redef]
811-
Found 1 error in 1 file (checked 2 source files)
812813
== Return code: 1
813814
$ dmypy recheck
814815
src/pkg/example.py:2: error: Incompatible import of "x" (imported name has type "int", local name has type "str") [assignment]
815-
Found 1 error in 1 file (checked 53 source files)
816816
== Return code: 1
817817
$ dmypy recheck
818818
src/pkg/example.py:2: error: Incompatible import of "x" (imported name has type "int", local name has type "str") [assignment]
819-
Found 1 error in 1 file (checked 53 source files)
820819
== Return code: 1
821820
[file mypy.ini]
822821
\[mypy]

0 commit comments

Comments
 (0)