blob: 478edb9e67af9fe16862ff7e9f149d50d24c2eb0 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
# frozen_string_literal: true
RSpec.describe "bundle version" do
context "with -v" do
it "outputs the version" do
bundle! "-v"
expect(out).to eq("Bundler version #{Bundler::VERSION}")
end
end
context "with --version" do
it "outputs the version" do
bundle! "--version"
expect(out).to eq("Bundler version #{Bundler::VERSION}")
end
end
context "with version" do
it "outputs the version with build metadata" do
date = Bundler::BuildMetadata.built_at
git_commit_sha = Bundler::BuildMetadata.git_commit_sha
bundle! "version"
expect(out).to eq("Bundler version #{Bundler::VERSION} (#{date} commit #{git_commit_sha})")
end
end
end
|