How to use the julia.core.JuliaInfo function in julia

To help you get started, we’ve selected a few julia examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github JuliaPy / pyjulia / test / test_juliainfo.py View on Github external
def test_juliainfo_failure():
    with pytest.raises(subprocess.CalledProcessError) as excinfo:
        JuliaInfo.load(julia="false")
    assert excinfo.value.cmd[0] == "false"
    assert excinfo.value.returncode == 1
    assert isinstance(excinfo.value.output, str)
github JuliaPy / pyjulia / test / test_libjulia.py View on Github external
import sys

import pytest

from .test_compatible_exe import runcode
from julia.core import JuliaInfo

juliainfo = JuliaInfo.load()


@pytest.mark.skipif("juliainfo.version_info < (0, 7)")
@pytest.mark.julia
def test_compiled_modules_no():
    runcode(
        sys.executable,
        """
        from julia.core import Julia

        Julia(debug=True, compiled_modules=False)

        from julia import Main
        use_compiled_modules = Main.eval("Base.JLOptions().use_compiled_modules")

        print("use_compiled_modules =", use_compiled_modules)
github JuliaPy / pyjulia / test / test_juliainfo.py View on Github external
def test_juliainfo_normal():
    jlinfo = JuliaInfo.load(os.getenv("PYJULIA_TEST_RUNTIME", "julia"))
    check_core_juliainfo(jlinfo)
    assert os.path.exists(jlinfo.python)
    # Note: jlinfo.libpython is probably not a full path so we are not