summaryrefslogtreecommitdiff
path: root/test cases/python/5 modules kwarg/meson.build
blob: 6e745ba62e934fe1965d67c98823d54f6b881795 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
project('python kwarg',
    default_options: [
        'python.bytecompile=-1',
        'python.purelibdir=/pure',
    ]
)

py = import('python')
prog_python = py.find_installation('python3', modules : ['os', 'sys', 're'], pure: true)
assert(prog_python.found() == true, 'python not found when should be')

# In meson 1.2 - 1.3.2, there was a bug when a python installation
# with a different version did not have a module, and we try to install
# something with another python version...
py.find_installation('python3.7', modules: ['notamodule'], required: false)
prog_python.install_sources('a.py')

prog_python = py.find_installation('python3', modules : ['thisbetternotexistmod'], required : false)
assert(prog_python.found() == false, 'python not found but reported as found')