diff options
| author | Jack Nagel | 2014-07-18 15:14:42 -0500 |
|---|---|---|
| committer | Jack Nagel | 2014-07-18 15:14:57 -0500 |
| commit | a87d2108ea6e8b4261ca3411ff3b30b0a6714eeb (patch) | |
| tree | 18bb7cea1667ae8d8b03a897d4367ff09ce370c4 /Library/Homebrew/test | |
| parent | 7d28a6c54bc361154a0d4b7be8e88baef5301c14 (diff) | |
| download | brew-a87d2108ea6e8b4261ca3411ff3b30b0a6714eeb.tar.bz2 | |
Move bottle filename construction to a class
Diffstat (limited to 'Library/Homebrew/test')
| -rw-r--r-- | Library/Homebrew/test/test_bottle_filename.rb | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/Library/Homebrew/test/test_bottle_filename.rb b/Library/Homebrew/test/test_bottle_filename.rb new file mode 100644 index 000000000..09dc29e5f --- /dev/null +++ b/Library/Homebrew/test/test_bottle_filename.rb @@ -0,0 +1,14 @@ +require "testing_env" +require "software_spec" + +class BottleFilenameTests < Homebrew::TestCase + def fn(revision) + Bottle::Filename.new("foo", "1.0", :tag, revision) + end + + def test_to_str + expected = "foo-1.0.tag.bottle.tar.gz" + assert_equal expected, fn(0).to_s + assert_equal expected, fn(0).to_str + end +end |
