def METHOD_NAME(
    rule_runner: RuleRunner,
    results: tuple[FmtResult, ...],
    *expected_results: ExpectedResult,
) -> None:
    assert len(results) == len(expected_results)
    for result, expected in zip(results, expected_results):
        assert result.stdout == expected.stdout
        assert result.stderr == expected.stderr
        for filename, contents in expected.files:
            fc = next(
                fc
                for fc in rule_runner.request(DigestContents, [result.output.digest])
                if fc.path == filename
            )
            assert fc.content.decode() == contents