diff options
| author | David Höppner | 2009-09-13 13:21:22 +0200 |
|---|---|---|
| committer | Max Howell | 2009-09-14 20:33:46 +0100 |
| commit | f150e5ece29d3e5c9bedfe557446a62380cd4f21 (patch) | |
| tree | 4d2c34da6916c4156402b64c01f092e6fe3d8556 | |
| parent | 6ee6bee01f8dfa3c931f287cfcc874bb7a232b84 (diff) | |
| download | brew-f150e5ece29d3e5c9bedfe557446a62380cd4f21.tar.bz2 | |
Fix unittest test_arch_for_command for 10.5
| -rwxr-xr-x | Library/Homebrew/unittest.rb | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/Library/Homebrew/unittest.rb b/Library/Homebrew/unittest.rb index 255b55601..15b0dc3cf 100755 --- a/Library/Homebrew/unittest.rb +++ b/Library/Homebrew/unittest.rb @@ -421,10 +421,13 @@ class BeerTasting <Test::Unit::TestCase end def test_arch_for_command - # NOTE only works on Snow Leopard I bet, pick a better file! arches=arch_for_command '/usr/bin/svn' - assert_equal 3, arches.count - assert arches.include?(:x86_64) + if `sw_vers -productVersion` =~ /10\.(\d)\.(\d+)/ and $1.to_i >= 6 + assert_equal 3, arches.count + assert arches.include?(:x86_64) + else + assert_equal 2, arches.count + end assert arches.include?(:i386) assert arches.include?(:ppc7400) end |
