diff options
| author | Bob W. Hogg | 2017-03-14 22:38:43 -0700 |
|---|---|---|
| committer | Shaun Jackman | 2017-11-26 08:37:57 -0800 |
| commit | 3cd869651beb0114580016aba46d2eda4a094523 (patch) | |
| tree | d5a7986e3ee15325c661fe48a00657e3512b3d3d /Library/Homebrew/test/support | |
| parent | 73942088733a5539599eb7132b6fc458bd50d873 (diff) | |
| download | brew-3cd869651beb0114580016aba46d2eda4a094523.tar.bz2 | |
Add test fixtures for ELF executables
Add test/support/fixtures/elf/
and test/support/fixtures/tarballs/testball-0.1-linux.tbz
Diffstat (limited to 'Library/Homebrew/test/support')
| -rwxr-xr-x | Library/Homebrew/test/support/fixtures/elf/hello | bin | 0 -> 6312 bytes | |||
| -rwxr-xr-x | Library/Homebrew/test/support/fixtures/elf/libhello.so.0 | bin | 0 -> 6312 bytes | |||
| -rw-r--r-- | Library/Homebrew/test/support/fixtures/tarballs/testball-0.1-linux.tbz | bin | 0 -> 3253 bytes | |||
| -rw-r--r-- | Library/Homebrew/test/support/helper/spec/shared_context/integration_test.rb | 9 | ||||
| -rw-r--r-- | Library/Homebrew/test/support/lib/config.rb | 1 |
5 files changed, 7 insertions, 3 deletions
diff --git a/Library/Homebrew/test/support/fixtures/elf/hello b/Library/Homebrew/test/support/fixtures/elf/hello Binary files differnew file mode 100755 index 000000000..76b86f02d --- /dev/null +++ b/Library/Homebrew/test/support/fixtures/elf/hello diff --git a/Library/Homebrew/test/support/fixtures/elf/libhello.so.0 b/Library/Homebrew/test/support/fixtures/elf/libhello.so.0 Binary files differnew file mode 100755 index 000000000..e85b7184f --- /dev/null +++ b/Library/Homebrew/test/support/fixtures/elf/libhello.so.0 diff --git a/Library/Homebrew/test/support/fixtures/tarballs/testball-0.1-linux.tbz b/Library/Homebrew/test/support/fixtures/tarballs/testball-0.1-linux.tbz Binary files differnew file mode 100644 index 000000000..5ca2be071 --- /dev/null +++ b/Library/Homebrew/test/support/fixtures/tarballs/testball-0.1-linux.tbz diff --git a/Library/Homebrew/test/support/helper/spec/shared_context/integration_test.rb b/Library/Homebrew/test/support/helper/spec/shared_context/integration_test.rb index da01580c2..6ee6a3345 100644 --- a/Library/Homebrew/test/support/helper/spec/shared_context/integration_test.rb +++ b/Library/Homebrew/test/support/helper/spec/shared_context/integration_test.rb @@ -123,11 +123,16 @@ RSpec.shared_context "integration test" do def setup_test_formula(name, content = nil) case name when /^testball/ + tarball = if OS.linux? + TEST_FIXTURE_DIR/"tarballs/testball-0.1-linux.tbz" + else + TEST_FIXTURE_DIR/"tarballs/testball-0.1.tbz" + end content = <<~EOS desc "Some test" homepage "https://example.com/#{name}" - url "file://#{TEST_FIXTURE_DIR}/tarballs/testball-0.1.tbz" - sha256 "#{TESTBALL_SHA256}" + url "file://#{tarball}" + sha256 "#{tarball.sha256}" option "with-foo", "Build with foo" diff --git a/Library/Homebrew/test/support/lib/config.rb b/Library/Homebrew/test/support/lib/config.rb index 3a0a76722..e54fc111f 100644 --- a/Library/Homebrew/test/support/lib/config.rb +++ b/Library/Homebrew/test/support/lib/config.rb @@ -35,7 +35,6 @@ HOMEBREW_TEMP = HOMEBREW_PREFIX.parent+"temp" TEST_FIXTURE_DIR = HOMEBREW_LIBRARY_PATH.join("test", "support", "fixtures") -TESTBALL_SHA1 = "be478fd8a80fe7f29196d6400326ac91dad68c37".freeze TESTBALL_SHA256 = "91e3f7930c98d7ccfb288e115ed52d06b0e5bc16fec7dce8bdda86530027067b".freeze TESTBALL_PATCHES_SHA256 = "799c2d551ac5c3a5759bea7796631a7906a6a24435b52261a317133a0bfb34d9".freeze PATCH_A_SHA256 = "83404f4936d3257e65f176c4ffb5a5b8d6edd644a21c8d8dcc73e22a6d28fcfa".freeze |
