Skip to content

minitest: progress characters glued after an unterminated print are dropped #116

Description

@rsanheim

Found while building the minitest-outcomes fixture (PR #115).

When a test does print with no trailing newline, minitest writes that test's own progress dot immediately after the partial text on the same physical line (e.g. PARTIAL_APARTIAL_B.). Any subsequent silent tests keep gluing their progress characters onto that same line until something writes a newline — so the glued run can include dots, F, E, or S depending on the random seed.

The parser's countLeadingProgressChars heuristic only extracts leading progress characters, and these lines start with test-written text, so every glued character is dropped. Result: the progress line under-counts, by an amount that varies with test order (observed 11 of 12 down to potentially 5 of 12 for the outcomes fixture).

Reproduce: plur -C fixtures/projects/minitest-outcomes --use minitest -n 1 — the progress line shows fewer than 12 characters for a 12-test run.

Characterized (not fixed) by the "under-counts progress when an unterminated print swallows the line" example in spec/integration/spec/minitest_outcomes_spec.rb; whatever replaces the current mixed-line handling (see #106 discussion) should flip that expectation to exactly 12.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions