mirror of
https://github.com/astral-sh/ruff.git
synced 2025-10-01 22:31:23 +00:00
[red-knot] Fix build on Windows (#12719)
## Summary Tests are failing on `main` because automerge landed https://github.com/astral-sh/ruff/pull/12716 despite the Windows tests failing.
This commit is contained in:
parent
7fa76a2b2b
commit
aae9619d3d
2 changed files with 5 additions and 3 deletions
|
@ -603,7 +603,6 @@ impl PackageKind {
|
|||
|
||||
#[cfg(test)]
|
||||
mod tests {
|
||||
use anyhow::Context;
|
||||
use ruff_db::files::{system_path_to_file, File, FilePath};
|
||||
use ruff_db::system::DbWithTestSystem;
|
||||
use ruff_db::testing::{
|
||||
|
@ -1133,10 +1132,13 @@ mod tests {
|
|||
#[test]
|
||||
#[cfg(target_family = "unix")]
|
||||
fn symlink() -> anyhow::Result<()> {
|
||||
use crate::db::tests::TestDb;
|
||||
use anyhow::Context;
|
||||
|
||||
use ruff_db::program::Program;
|
||||
use ruff_db::system::{OsSystem, SystemPath};
|
||||
|
||||
use crate::db::tests::TestDb;
|
||||
|
||||
let mut db = TestDb::new();
|
||||
|
||||
let temp_dir = tempfile::tempdir()?;
|
||||
|
|
|
@ -35,7 +35,7 @@ fn site_packages_dir_from_sys_prefix(
|
|||
sys_prefix_path: &SystemPath,
|
||||
system: &dyn System,
|
||||
) -> Result<SystemPathBuf, SitePackagesDiscoveryError> {
|
||||
let site_packages = venv_path.join("Lib/site-packages");
|
||||
let site_packages = sys_prefix_path.join("Lib/site-packages");
|
||||
system
|
||||
.is_directory(&site_packages)
|
||||
.then_some(site_packages)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue