aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/test
diff options
context:
space:
mode:
authorBaptiste Fontaine2015-01-28 09:28:20 +0100
committerMike McQuaid2015-01-28 14:19:21 +0000
commita9e8dfb9960b6d3c75f7152a16f7496b41679943 (patch)
treeabc6d48a2c600dd2c450a9d7aa984f63b95e9185 /Library/Homebrew/test
parent5ac0446fd704dd9af4b507bdbb9cd373b1929f7c (diff)
downloadbrew-a9e8dfb9960b6d3c75f7152a16f7496b41679943.tar.bz2
Fix version misdetections for URLs with OS/archs
Closes Homebrew/homebrew#36308. Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
Diffstat (limited to 'Library/Homebrew/test')
-rw-r--r--Library/Homebrew/test/test_versions.rb14
1 files changed, 14 insertions, 0 deletions
diff --git a/Library/Homebrew/test/test_versions.rb b/Library/Homebrew/test/test_versions.rb
index 2c6c2e8fb..52352ce8d 100644
--- a/Library/Homebrew/test/test_versions.rb
+++ b/Library/Homebrew/test/test_versions.rb
@@ -342,4 +342,18 @@ class VersionParsingTests < Homebrew::TestCase
assert_version_detected '2.4c',
'http://loop-aes.sourceforge.net/aespipe/aespipe-v2.4c.tar.bz2'
end
+
+ def test_win_style
+ assert_version_detected '0.9.17',
+ 'http://ftpmirror.gnu.org/libmicrohttpd/libmicrohttpd-0.9.17-w32.zip'
+ assert_version_detected '1.29',
+ 'http://ftpmirror.gnu.org/libidn/libidn-1.29-win64.zip'
+ end
+
+ def test_with_arch
+ assert_version_detected '4.0.18-1',
+ 'http://ftpmirror.gnu.org/mtools/mtools-4.0.18-1.i686.rpm'
+ assert_version_detected '2.8',
+ 'http://ftpmirror.gnu.org/libtasn1/libtasn1-2.8-x86.zip'
+ end
end