test/relocate.py: skip tests involving patchelf on macOS (#18451)
This commit is contained in:
parent
ea97b37f60
commit
ae44a8ff64
@ -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'
|
||||
|
Loading…
Reference in New Issue
Block a user