From d1987b287af99285e2bb8ebb3f39ea8ca6f16afe Mon Sep 17 00:00:00 2001 From: Dan Date: Sun, 16 Nov 2025 13:13:50 -0500 Subject: [PATCH] Revert "Update analyze_graph.rs" This reverts commit 2cc5cb708af569250bd27a5d5890de92bfef5807. --- crates/ruff/tests/cli/analyze_graph.rs | 64 +++++++++++++------------- 1 file changed, 32 insertions(+), 32 deletions(-) diff --git a/crates/ruff/tests/cli/analyze_graph.rs b/crates/ruff/tests/cli/analyze_graph.rs index 90c6b175fa..f0edb291c7 100644 --- a/crates/ruff/tests/cli/analyze_graph.rs +++ b/crates/ruff/tests/cli/analyze_graph.rs @@ -27,43 +27,43 @@ fn type_checking_imports() -> anyhow::Result<()> { ("ruff/c.py", ""), ])?; - assert_cmd_snapshot!(test.analyze_graph_command(), @r#" + assert_cmd_snapshot!(test.analyze_graph_command(), @r###" success: true exit_code: 0 ----- stdout ----- { - "ruff\/__init__.py": [], - "ruff\\a.py": [ - "ruff\\b.py", - "ruff\\c.py" + "ruff/__init__.py": [], + "ruff/a.py": [ + "ruff/b.py", + "ruff/c.py" ], - "ruff\\b.py": [ - "ruff\\c.py" + "ruff/b.py": [ + "ruff/c.py" ], - "ruff\\c.py": [] + "ruff/c.py": [] } ----- stderr ----- - "#); + "###); assert_cmd_snapshot!( test.analyze_graph_command() .arg("--no-type-checking-imports"), - @r#" + @r###" success: true exit_code: 0 ----- stdout ----- { - "ruff\/__init__.py": [], - "ruff\\a.py": [ - "ruff\\b.py" + "ruff/__init__.py": [], + "ruff/a.py": [ + "ruff/b.py" ], - "ruff\\b.py": [], - "ruff\\c.py": [] + "ruff/b.py": [], + "ruff/c.py": [] } ----- stderr ----- - "# + "### ); Ok(()) @@ -101,21 +101,21 @@ fn type_checking_imports_from_config() -> anyhow::Result<()> { ), ])?; - assert_cmd_snapshot!(test.analyze_graph_command(), @r#" + assert_cmd_snapshot!(test.analyze_graph_command(), @r###" success: true exit_code: 0 ----- stdout ----- { - "ruff\/__init__.py": [], - "ruff\\a.py": [ - "ruff\\b.py" + "ruff/__init__.py": [], + "ruff/a.py": [ + "ruff/b.py" ], - "ruff\\b.py": [], - "ruff\\c.py": [] + "ruff/b.py": [], + "ruff/c.py": [] } ----- stderr ----- - "#); + "###); test.write_file( "ruff.toml", @@ -125,24 +125,24 @@ fn type_checking_imports_from_config() -> anyhow::Result<()> { "#, )?; - assert_cmd_snapshot!(test.analyze_graph_command(), @r#" + assert_cmd_snapshot!(test.analyze_graph_command(), @r###" success: true exit_code: 0 ----- stdout ----- { - "ruff\/__init__.py": [], - "ruff\\a.py": [ - "ruff\\b.py", - "ruff\\c.py" + "ruff/__init__.py": [], + "ruff/a.py": [ + "ruff/b.py", + "ruff/c.py" ], - "ruff\\b.py": [ - "ruff\\c.py" + "ruff/b.py": [ + "ruff/c.py" ], - "ruff\\c.py": [] + "ruff/c.py": [] } ----- stderr ----- - "# + "### ); Ok(())