Skip to content

Commit 991d0a2

Browse files
committed
Fix specs for new default branch, bump development Ruby -> 2.7.2
Since the default branch became `main`, some specs that relied on the default being `master` were failing. This change adds setup for examples that depend on the old `master` branch being the default branch so that the specs continue to work for both cases. Bump the development version of Ruby to 2.7.2.
1 parent e2d0d9c commit 991d0a2

File tree

2 files changed

+11
-3
lines changed

2 files changed

+11
-3
lines changed

.ruby-version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2.5.3
1+
2.7.2

spec/parity/environment_spec.rb

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -233,13 +233,21 @@
233233
it "returns false if the deploy was not succesful" do
234234
allow(Kernel).to receive(:system).with(git_push).and_return(false)
235235

236-
result = Parity::Environment.new("production", ["deploy"]).run
236+
env = Parity::Environment.new("production", ["deploy"])
237+
238+
allow(env).to receive(:branch_ref).and_return("master")
239+
240+
result = env.run
237241

238242
expect(result).to eq(false)
239243
end
240244

241245
it "deploys feature branches to staging's master for evaluation" do
242-
Parity::Environment.new("staging", ["deploy"]).run
246+
env = Parity::Environment.new("staging", ["deploy"])
247+
248+
allow(env).to receive(:branch_ref).and_return("master")
249+
250+
env.run
243251

244252
expect(Kernel).to have_received(:system).with(git_push_feature_branch)
245253
end

0 commit comments

Comments
 (0)