-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Consistant Capistrano::VERSION interface
The latest version of Capistrano uses Capistrano::VERSION for storing the gem version. This change adds a constant to match this interface for v2.
- Loading branch information
Sasha Gerrand
authored and
Lee Hambley
committed
Jun 17, 2015
1 parent
bbc7abb
commit c971854
Showing
2 changed files
with
13 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,4 +8,6 @@ def self.to_s | |
"#{MAJOR}.#{MINOR}.#{PATCH}" | ||
end | ||
end | ||
|
||
VERSION = Version.to_s | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
require 'capistrano/version' | ||
|
||
class VersionTest < Test::Unit::TestCase | ||
def test_version_constant_is_not_nil | ||
assert_not_nil Capistrano::VERSION | ||
end | ||
|
||
def test_version_constant_matches_class_method | ||
assert_equal Capistrano::VERSION, Capistrano::Version.to_s | ||
end | ||
end |