From ae44a8ff644629adbf61440383939cc670d1d390 Mon Sep 17 00:00:00 2001 From: Patrick Gartung Date: Tue, 1 Sep 2020 14:49:05 -0500 Subject: test/relocate.py: skip tests involving patchelf on macOS (#18451) --- lib/spack/spack/test/relocate.py | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'lib') diff --git a/lib/spack/spack/test/relocate.py b/lib/spack/spack/test/relocate.py index a1a8952c97..f9e72ea0d7 100644 --- a/lib/spack/spack/test/relocate.py +++ b/lib/spack/spack/test/relocate.py @@ -271,6 +271,10 @@ def test_set_elf_rpaths_warning(mock_patchelf): @pytest.mark.requires_executables('patchelf', 'strings', 'file', 'gcc') +@pytest.mark.skipif( + platform.system().lower() != 'linux', + reason='implementation for MacOS still missing' +) def test_replace_prefix_bin(hello_world): # Compile an "Hello world!" executable and set RPATHs executable = hello_world(rpaths=['/usr/lib', '/usr/lib64']) @@ -283,6 +287,10 @@ def test_replace_prefix_bin(hello_world): @pytest.mark.requires_executables('patchelf', 'strings', 'file', 'gcc') +@pytest.mark.skipif( + platform.system().lower() != 'linux', + reason='implementation for MacOS still missing' +) def test_relocate_elf_binaries_absolute_paths( hello_world, copy_binary, tmpdir ): @@ -307,6 +315,10 @@ def test_relocate_elf_binaries_absolute_paths( @pytest.mark.requires_executables('patchelf', 'strings', 'file', 'gcc') +@pytest.mark.skipif( + platform.system().lower() != 'linux', + reason='implementation for MacOS still missing' +) def test_relocate_elf_binaries_relative_paths(hello_world, copy_binary): # Create an executable, set some RPATHs, copy it to another location orig_binary = hello_world(rpaths=['lib', 'lib64', '/opt/local/lib']) @@ -327,6 +339,10 @@ def test_relocate_elf_binaries_relative_paths(hello_world, copy_binary): @pytest.mark.requires_executables('patchelf', 'strings', 'file', 'gcc') +@pytest.mark.skipif( + platform.system().lower() != 'linux', + reason='implementation for MacOS still missing' +) def test_make_elf_binaries_relative(hello_world, copy_binary, tmpdir): orig_binary = hello_world(rpaths=[ str(tmpdir.mkdir('lib')), str(tmpdir.mkdir('lib64')), '/opt/local/lib' @@ -350,6 +366,10 @@ def test_raise_if_not_relocatable(monkeypatch): @pytest.mark.requires_executables('patchelf', 'strings', 'file', 'gcc') +@pytest.mark.skipif( + platform.system().lower() != 'linux', + reason='implementation for MacOS still missing' +) def test_relocate_text_bin(hello_world, copy_binary, tmpdir): orig_binary = hello_world(rpaths=[ str(tmpdir.mkdir('lib')), str(tmpdir.mkdir('lib64')), '/opt/local/lib' -- cgit v1.2.3-70-g09d2