tests/functional/commands/conftest.py
def two_experiments(monkeypatch, db_instance):
    """Create an experiment and its child."""
    monkeypatch.chdir(os.path.dirname(os.path.abspath(__file__)))
    orion.core.cli.main(
        [
            "hunt",
            "--init-only",
            "-n",
            "test_double_exp",
            "./black_box.py",
            "--x~uniform(0,1)",
        ]
    )
    ensure_deterministic_id("test_double_exp", db_instance)

    orion.core.cli.main(
        [
            "hunt",
            "--init-only",
            "-n",
            "test_double_exp",
            "--branch-to",
            "test_double_exp_child",
            "./black_box.py",
            "--x~+uniform(0,1,default_value=0)",
            "--y~+uniform(0,1,default_value=0)",
        ]
    )
    ensure_deterministic_id("test_double_exp_child", db_instance)
Create an experiment and its child.
Create an experiment and its child.
Create an experiment and its child .
def two_experiments(monkeypatch, db_instance):
    monkeypatch.chdir(os.path.dirname(os.path.abspath(__file__)))
    orion.core.cli.main(
        [
            "hunt",
            "--init-only",
            "-n",
            "test_double_exp",
            "./black_box.py",
            "--x~uniform(0,1)",
        ]
    )
    ensure_deterministic_id("test_double_exp", db_instance)
    orion.core.cli.main(
        [
            "hunt",
            "--init-only",
            "-n",
            "test_double_exp",
            "--branch-to",
            "test_double_exp_child",
            "./black_box.py",
            "--x~+uniform(0,1,default_value=0)",
            "--y~+uniform(0,1,default_value=0)",
        ]
    )
    ensure_deterministic_id("test_double_exp_child", db_instance)
def two_experiments ( monkeypatch , db_instance ) : monkeypatch . chdir ( os . path . dirname ( os . path . abspath ( __file__ ) ) ) orion . core . cli . main ( [ "hunt" , "--init-only" , "-n" , "test_double_exp" , "./black_box.py" , "--x~uniform(0,1)" , ] ) ensure_deterministic_id ( "test_double_exp" , db_instance ) orion . core . cli . main ( [ "hunt" , "--init-only" , "-n" , "test_double_exp" , "--branch-to" , "test_double_exp_child" , "./black_box.py" , "--x~+uniform(0,1,default_value=0)" , "--y~+uniform(0,1,default_value=0)" , ] ) ensure_deterministic_id ( "test_double_exp_child" , db_instance )
Create an experiment and its child.
Create an experiment and its child .
"""Create an experiment and its child."""
monkeypatch
db_instance