mirror of
https://github.com/Homebrew/brew.git
synced 2025-07-14 16:09:03 +08:00
git grep -l '^shared_examples' | xargs gsed -i 's|^shared_examples|RSpec.shared_examples|g'
This commit is contained in:
parent
26eda5a303
commit
ab8f5702ac
@ -2,7 +2,7 @@
|
||||
|
||||
require "benchmark"
|
||||
|
||||
shared_examples "#uninstall_phase or #zap_phase" do
|
||||
RSpec.shared_examples "#uninstall_phase or #zap_phase" do
|
||||
subject { artifact }
|
||||
|
||||
let(:artifact_dsl_key) { described_class.dsl_key }
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
require "cask/dsl/base"
|
||||
|
||||
shared_examples Cask::DSL::Base do
|
||||
RSpec.shared_examples Cask::DSL::Base do
|
||||
it "supports the token method" do
|
||||
expect(dsl.token).to eq(cask.token)
|
||||
end
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
require "cask/staged"
|
||||
|
||||
shared_examples Cask::Staged do
|
||||
RSpec.shared_examples Cask::Staged do
|
||||
let(:existing_path) { Pathname("/path/to/file/that/exists") }
|
||||
let(:non_existent_path) { Pathname("/path/to/file/that/does/not/exist") }
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
shared_examples "parseable arguments" do
|
||||
RSpec.shared_examples "parseable arguments" do
|
||||
subject(:method_name) { "#{command_name.tr("-", "_")}_args" }
|
||||
|
||||
let(:command_name) do |example|
|
||||
|
@ -1,6 +1,6 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
shared_examples "formulae exist" do |array|
|
||||
RSpec.shared_examples "formulae exist" do |array|
|
||||
array.each do |f|
|
||||
it "#{f} formula exists" do
|
||||
core_tap = Pathname("#{HOMEBREW_LIBRARY_PATH}/../Taps/homebrew/homebrew-core")
|
||||
|
@ -2,13 +2,13 @@
|
||||
|
||||
require "unpack_strategy"
|
||||
|
||||
shared_examples "UnpackStrategy::detect" do
|
||||
RSpec.shared_examples "UnpackStrategy::detect" do
|
||||
it "is correctly detected" do
|
||||
expect(UnpackStrategy.detect(path)).to be_a described_class
|
||||
end
|
||||
end
|
||||
|
||||
shared_examples "#extract" do |children: []|
|
||||
RSpec.shared_examples "#extract" do |children: []|
|
||||
specify "#extract" do
|
||||
mktmpdir do |unpack_dir|
|
||||
described_class.new(path).extract(to: unpack_dir)
|
||||
|
Loading…
x
Reference in New Issue
Block a user