Ejemplo n.º 1
0
def test_tar_distributions(cfg):
    for dist in it.DISTRIBUTIONS:
        for track in it.TRACKS:
            it.wait_until_port_is_free()
            assert it.race(
                cfg, f"--distribution-version=\"{dist}\" --track=\"{track}\" "
                f"--test-mode --car=4gheap") == 0
Ejemplo n.º 2
0
def test_docker_distribution(cfg):
    # only test the most recent Docker distribution
    dist = it.DISTRIBUTIONS[-1]
    it.wait_until_port_is_free(port_number=19200)
    assert it.race(cfg, f"--pipeline=\"docker\" --distribution-version=\"{dist}\" "
                           f"--track=\"geonames\" --challenge=\"append-no-conflicts-index-only\" --test-mode "
                           f"--car=4gheap --target-hosts=127.0.0.1:19200") == 0
Ejemplo n.º 3
0
def test_sources(cfg):
    it.wait_until_port_is_free()
    assert it.esrally(cfg, "--on-error=abort --revision=latest --track=geonames --test-mode "
                           "--challenge=append-no-conflicts --car=4gheap --elasticsearch-plugins=analysis-icu") == 0

    it.wait_until_port_is_free()
    assert it.esrally(cfg, "--on-error=abort --pipeline=from-sources-skip-build --track=geonames --test-mode "
                           "--challenge=append-no-conflicts-index-only --car=\"4gheap,ea\"") == 0
Ejemplo n.º 4
0
def test_tar_distributions(cfg):
    port = 19200
    for dist in it.DISTRIBUTIONS:
        for track in it.TRACKS:
            it.wait_until_port_is_free(port_number=port)
            assert it.race(
                cfg, f"--distribution-version=\"{dist}\" --track=\"{track}\" "
                f"--test-mode --car=4gheap --target-hosts=127.0.0.1:{port}"
            ) == 0
Ejemplo n.º 5
0
def test_does_not_benchmark_unsupported_distribution(cfg):
    port = 19200
    it.wait_until_port_is_free(port_number=port)
    assert (
        it.race(
            cfg, f'--distribution-version="1.7.6" --track="{it.TRACKS[0]}" ' f"--target-hosts=127.0.0.1:{port} --test-mode --car=4gheap"
        )
        != 0
    )
Ejemplo n.º 6
0
def test_track_dependencies(cfg):
    port = 19200
    it.wait_until_port_is_free(port_number=port)
    dist_version = it.DISTRIBUTIONS[-1]
    cwd = os.path.dirname(__file__)
    track_path = os.path.join(cwd, "resources", "track_with_dependency")
    # workaround for MacOS and Python deficiency. http://sealiesoftware.com/blog/archive/2017/6/5/Objective-C_and_fork_in_macOS_1013.html
    os.environ["OBJC_DISABLE_INITIALIZE_FORK_SAFETY"] = "YES"
    assert it.race(
        cfg,
        f"--distribution-version={dist_version} --track-path={track_path} --car=4gheap,basic-license"
    ) == 0
Ejemplo n.º 7
0
def test_cluster():
    cluster = it.TestCluster("in-memory-it")
    # test with a recent distribution
    dist = it.DISTRIBUTIONS[-1]
    port = 49200
    race_id = str(uuid.uuid4())

    it.wait_until_port_is_free(port_number=port)
    cluster.install(distribution_version=dist, node_name="rally-node", car="4gheap", http_port=port)
    cluster.start(race_id=race_id)
    yield cluster
    cluster.stop()
Ejemplo n.º 8
0
def test_tar_distributions(cfg):
    port = 19200
    for dist in it.DISTRIBUTIONS:
        for track in it.TRACKS:
            it.wait_until_port_is_free(port_number=port)
            assert (
                it.race(
                    cfg,
                    f'--distribution-version="{dist}" --track="{track}" '
                    f"--test-mode --car=4gheap,basic-license --target-hosts=127.0.0.1:{port}",
                )
                == 0
            )
Ejemplo n.º 9
0
def test_docker_distribution(cfg):
    port = 19200
    # only test the most recent Docker distribution
    dist = it.DISTRIBUTIONS[-1]
    it.wait_until_port_is_free(port_number=port)
    assert (
        it.race(
            cfg,
            f'--pipeline="docker" --distribution-version="{dist}" '
            f'--track="geonames" --challenge="append-no-conflicts-index-only" --test-mode '
            f"--car=4gheap,basic-license --target-hosts=127.0.0.1:{port}",
        )
        == 0
    )
Ejemplo n.º 10
0
def test_sources(cfg):
    port = 19200
    it.wait_until_port_is_free(port_number=port)
    assert it.race(
        cfg,
        f"--revision=latest --track=geonames --test-mode  --target-hosts=127.0.0.1:{port} "
        f"--challenge=append-no-conflicts --car=4gheap --elasticsearch-plugins=analysis-icu"
    ) == 0

    it.wait_until_port_is_free(port_number=port)
    assert it.race(
        cfg,
        f"--pipeline=from-sources --track=geonames --test-mode --target-hosts=127.0.0.1:{port} "
        f"--challenge=append-no-conflicts-index-only --car=\"4gheap,ea\"") == 0