mirror of
https://github.com/starship/starship.git
synced 2026-06-23 02:05:51 +07:00
Add support for detecting Python from Pipenv files (#221)
Added the ability to enable the Python module based on the existence of the a `Pipfile`.
This commit is contained in:
committed by
Kevin Song
parent
360ea988e5
commit
1478f8c2e9
@@ -57,6 +57,23 @@ fn folder_with_pyproject_toml() -> io::Result<()> {
|
||||
Ok(())
|
||||
}
|
||||
|
||||
#[test]
|
||||
#[ignore]
|
||||
fn folder_with_pipfile() -> io::Result<()> {
|
||||
let dir = common::new_tempdir()?;
|
||||
File::create(dir.path().join("Pipfile"))?;
|
||||
|
||||
let output = common::render_module("python")
|
||||
.arg("--path")
|
||||
.arg(dir.path())
|
||||
.output()?;
|
||||
let actual = String::from_utf8(output.stdout).unwrap();
|
||||
|
||||
let expected = format!("via {} ", Color::Yellow.bold().paint("🐍 v3.6.9"));
|
||||
assert_eq!(expected, actual);
|
||||
Ok(())
|
||||
}
|
||||
|
||||
#[test]
|
||||
#[ignore]
|
||||
fn folder_with_py_file() -> io::Result<()> {
|
||||
|
||||
Reference in New Issue
Block a user