Wrapping it up
This commit is contained in:
parent
4cc7463e65
commit
5b8d21c8cd
@ -167,7 +167,7 @@ class SystemCommand
|
||||
args: T::Array[T.any(String, Integer, Float, Pathname, URI::Generic)],
|
||||
sudo: T::Boolean,
|
||||
sudo_as_root: T::Boolean,
|
||||
env: T::Hash[String, T.nilable(String)],
|
||||
env: T::Hash[String, T.any(NilClass, String, T::Boolean)],
|
||||
input: T.any(String, T::Array[String]),
|
||||
must_succeed: T::Boolean,
|
||||
print_stdout: T.any(T::Boolean, Symbol),
|
||||
@ -376,7 +376,7 @@ class SystemCommand
|
||||
|
||||
sig {
|
||||
params(
|
||||
env: T::Hash[String, String],
|
||||
env: T::Hash[String, T.nilable(String)],
|
||||
executable: String,
|
||||
args: String,
|
||||
options: T.untyped,
|
||||
|
@ -440,7 +440,7 @@ RSpec.describe Homebrew::DevCmd::Bottle do
|
||||
old_spec = BottleSpecification.new
|
||||
old_spec.rebuild(1)
|
||||
new_hash = { "rebuild" => 2 }
|
||||
expect(homebrew.merge_bottle_spec(["rebuild"], old_spec, new_hash)).to eq [
|
||||
expect(homebrew.merge_bottle_spec([:rebuild], old_spec, new_hash)).to eq [
|
||||
['rebuild: old: "1", new: "2"'],
|
||||
[],
|
||||
]
|
||||
|
@ -191,7 +191,7 @@ RSpec.describe CurlDownloadStrategy do
|
||||
hash_including(args: array_including_cons("#{artifact_domain}/#{resource_path}")),
|
||||
)
|
||||
.at_least(:once)
|
||||
.and_return(SystemCommand::Result.new(["curl"], [""], status, secrets: []))
|
||||
.and_return(SystemCommand::Result.new(["curl"], [[:stdout, ""]], status, secrets: []))
|
||||
|
||||
strategy.fetch
|
||||
end
|
||||
|
@ -110,7 +110,10 @@ RSpec.describe Homebrew::Livecheck::Strategy::HeaderMatch do
|
||||
|
||||
it "errors on an invalid return type from a block" do
|
||||
expect { header_match.versions_from_headers(headers) { 123 } }
|
||||
.to raise_error(TypeError, Homebrew::Livecheck::Strategy::INVALID_BLOCK_RETURN_VALUE_MSG)
|
||||
.to raise_error(
|
||||
TypeError,
|
||||
/#{Homebrew::Livecheck::Strategy::INVALID_BLOCK_RETURN_VALUE_MSG}|Expected type T::Hash\[String, String\]/o,
|
||||
)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
Loading…
x
Reference in New Issue
Block a user