python: add --no-user when doing pip install
This commit is contained in:
parent
19a47d7c50
commit
425535e32b
@ -287,7 +287,7 @@ module Language
|
|||||||
targets = Array(targets)
|
targets = Array(targets)
|
||||||
@formula.system @venv_root/"bin/pip", "install",
|
@formula.system @venv_root/"bin/pip", "install",
|
||||||
"-v", "--no-deps", "--no-binary", ":all:",
|
"-v", "--no-deps", "--no-binary", ":all:",
|
||||||
"--ignore-installed", *targets
|
"--no-user", "--ignore-installed", *targets
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
@ -96,7 +96,7 @@ describe Language::Python::Virtualenv::Virtualenv do
|
|||||||
it "accepts a string" do
|
it "accepts a string" do
|
||||||
expect(formula).to receive(:system)
|
expect(formula).to receive(:system)
|
||||||
.with(dir/"bin/pip", "install", "-v", "--no-deps",
|
.with(dir/"bin/pip", "install", "-v", "--no-deps",
|
||||||
"--no-binary", ":all:", "--ignore-installed", "foo")
|
"--no-binary", ":all:", "--no-user", "--ignore-installed", "foo")
|
||||||
.and_return(true)
|
.and_return(true)
|
||||||
subject.pip_install "foo"
|
subject.pip_install "foo"
|
||||||
end
|
end
|
||||||
@ -104,7 +104,7 @@ describe Language::Python::Virtualenv::Virtualenv do
|
|||||||
it "accepts a multi-line strings" do
|
it "accepts a multi-line strings" do
|
||||||
expect(formula).to receive(:system)
|
expect(formula).to receive(:system)
|
||||||
.with(dir/"bin/pip", "install", "-v", "--no-deps",
|
.with(dir/"bin/pip", "install", "-v", "--no-deps",
|
||||||
"--no-binary", ":all:", "--ignore-installed", "foo", "bar")
|
"--no-binary", ":all:", "--no-user", "--ignore-installed", "foo", "bar")
|
||||||
.and_return(true)
|
.and_return(true)
|
||||||
|
|
||||||
subject.pip_install <<~EOS
|
subject.pip_install <<~EOS
|
||||||
@ -116,12 +116,12 @@ describe Language::Python::Virtualenv::Virtualenv do
|
|||||||
it "accepts an array" do
|
it "accepts an array" do
|
||||||
expect(formula).to receive(:system)
|
expect(formula).to receive(:system)
|
||||||
.with(dir/"bin/pip", "install", "-v", "--no-deps",
|
.with(dir/"bin/pip", "install", "-v", "--no-deps",
|
||||||
"--no-binary", ":all:", "--ignore-installed", "foo")
|
"--no-binary", ":all:", "--no-user", "--ignore-installed", "foo")
|
||||||
.and_return(true)
|
.and_return(true)
|
||||||
|
|
||||||
expect(formula).to receive(:system)
|
expect(formula).to receive(:system)
|
||||||
.with(dir/"bin/pip", "install", "-v", "--no-deps",
|
.with(dir/"bin/pip", "install", "-v", "--no-deps",
|
||||||
"--no-binary", ":all:", "--ignore-installed", "bar")
|
"--no-binary", ":all:", "--no-user", "--ignore-installed", "bar")
|
||||||
.and_return(true)
|
.and_return(true)
|
||||||
|
|
||||||
subject.pip_install ["foo", "bar"]
|
subject.pip_install ["foo", "bar"]
|
||||||
@ -133,7 +133,7 @@ describe Language::Python::Virtualenv::Virtualenv do
|
|||||||
expect(res).to receive(:stage).and_yield
|
expect(res).to receive(:stage).and_yield
|
||||||
expect(formula).to receive(:system)
|
expect(formula).to receive(:system)
|
||||||
.with(dir/"bin/pip", "install", "-v", "--no-deps",
|
.with(dir/"bin/pip", "install", "-v", "--no-deps",
|
||||||
"--no-binary", ":all:", "--ignore-installed", Pathname.pwd)
|
"--no-binary", ":all:", "--no-user", "--ignore-installed", Pathname.pwd)
|
||||||
.and_return(true)
|
.and_return(true)
|
||||||
|
|
||||||
subject.pip_install res
|
subject.pip_install res
|
||||||
|
Loading…
x
Reference in New Issue
Block a user