mirror of
https://github.com/rust-vmm/rust-vmm-ci.git
synced 2026-08-05 03:08:31 +00:00
This pipeline contains the tests that are currently run for kvm-ioctls. The pipeline also has a step that runs the coverage test defined in integration_tests/test_coverage.py. The purpose of this pipeline is to be used by all rust-vmm repositories to ensure we keep the same quality bar for all crates. Signed-off-by: Andreea Florescu <fandree@amazon.com>
31 lines
689 B
Python
31 lines
689 B
Python
# Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved.
|
|
# SPDX-License-Identifier: Apache-2.0
|
|
import pytest
|
|
|
|
|
|
PROFILE_CI="ci"
|
|
PROFILE_DEVEL="devel"
|
|
|
|
|
|
def pytest_addoption(parser):
|
|
parser.addoption(
|
|
"--profile",
|
|
default=PROFILE_CI,
|
|
choices=[PROFILE_CI, PROFILE_DEVEL],
|
|
help="Profile for running the test: {} or {}".format(
|
|
PROFILE_CI,
|
|
PROFILE_DEVEL
|
|
)
|
|
)
|
|
|
|
|
|
@pytest.fixture
|
|
def profile(request):
|
|
return request.config.getoption("--profile")
|
|
|
|
|
|
# This is used for defining global variables in pytest.
|
|
def pytest_configure():
|
|
pytest.profile_ci = PROFILE_CI
|
|
pytest.profile_devel = PROFILE_DEVEL
|