Skip to content

Commit

Permalink
fix duplicate test names (#197)
Browse files Browse the repository at this point in the history
  • Loading branch information
kaeraali-flutterint authored Nov 13, 2023
1 parent 10a502b commit bae14d8
Show file tree
Hide file tree
Showing 13 changed files with 13 additions and 13 deletions.
2 changes: 1 addition & 1 deletion test/azure/functional/test_azure.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
LOG = logger.get_logger(__name__)


def test_command_init_scenario(temp_dir):
def test_azure_command_init_scenario(temp_dir):
role_directory = os.path.join(temp_dir.strpath, "test_init")
cmd = ["ansible-galaxy", "role", "init", "test_init"]
result = run_command(cmd)
Expand Down
2 changes: 1 addition & 1 deletion test/azure/test_driver.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
from molecule import api


def test_driver_is_detected():
def test_azure_driver_is_detected():
assert "azure" in [str(d) for d in api.drivers()]
2 changes: 1 addition & 1 deletion test/containers/functional/test_containers.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
LOG = logger.get_logger(__name__)


def test_command_init_scenario(temp_dir):
def test_containers_command_init_scenario(temp_dir):
"""Verify that we can initialize a new scenario with this driver."""
with change_dir_to(temp_dir):
scenario_directory = os.path.join(molecule_directory(), "default")
Expand Down
2 changes: 1 addition & 1 deletion test/containers/test_driver.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@
from molecule import api


def test_driver_is_detected():
def test_container_driver_is_detected():
"""Check that driver is recognized."""
assert "containers" in [str(d) for d in api.drivers()]
2 changes: 1 addition & 1 deletion test/docker/test_driver.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@
from molecule import api


def test_driver_is_detected(DRIVER):
def test_docker_driver_is_detected(DRIVER):
"""Asserts that molecule recognizes the driver."""
assert DRIVER in [str(d) for d in api.drivers()]
2 changes: 1 addition & 1 deletion test/ec2/functional/test_ec2.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@


@pytest.mark.xfail(reason="need to fix template path")
def test_command_init_scenario(temp_dir):
def test_ec2_command_init_scenario(temp_dir):
role_directory = os.path.join(temp_dir.strpath, "test-init")
cmd = ["molecule", "init", "role", "test-init"]
assert run_command(cmd).returncode == 0
Expand Down
2 changes: 1 addition & 1 deletion test/ec2/test_driver.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
from molecule import api


def test_driver_is_detected():
def test_ec2_driver_is_detected():
assert "ec2" in [str(d) for d in api.drivers()]
2 changes: 1 addition & 1 deletion test/gce/functional/test_func.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@


@pytest.mark.xfail(reason="need to fix template path")
def test_command_init_scenario(temp_dir):
def test_gce_command_init_scenario(temp_dir):
"""Test init scenario with driver."""
role_directory = os.path.join(temp_dir.strpath, "test-init")
cmd = ["molecule", "init", "role", "test-init"]
Expand Down
2 changes: 1 addition & 1 deletion test/gce/test_driver.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from molecule import api


def test_driver_is_detected():
def test_gce_driver_is_detected():
driver_name = __name__.split(".")[0].split("_")[-1]
drivers = [str(d) for d in api.drivers()]
assert driver_name in drivers
2 changes: 1 addition & 1 deletion test/podman/test_driver.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
from molecule_plugins.podman.driver import Podman


def test_driver_is_detected():
def test_podman_driver_is_detected():
"""Asserts that molecule recognizes the driver."""
assert any(str(d) == "podman" for d in api.drivers())

Expand Down
2 changes: 1 addition & 1 deletion test/podman/test_func.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ def format_result(result: subprocess.CompletedProcess):
)


def test_command_init_scenario(tmp_path: pathlib.Path):
def test_podman_command_init_scenario(tmp_path: pathlib.Path):
"""Verify that init scenario works."""
scenario_name = "default"

Expand Down
2 changes: 1 addition & 1 deletion test/vagrant/functional/test_func.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ def is_vagrant_supported() -> bool:
not is_vagrant_supported(),
reason="vagrant not supported on this machine",
)
def test_command_init_scenario(temp_dir):
def test_vagrant_command_init_scenario(temp_dir):
with change_dir_to(temp_dir):
os.makedirs(os.path.join(temp_dir, "molecule", "default"))
scenario_directory = os.path.join(temp_dir, "molecule", "test-scenario")
Expand Down
2 changes: 1 addition & 1 deletion test/vagrant/test_driver.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
from molecule import api


def test_driver_is_detected():
def test_vagrant_driver_is_detected():
assert "vagrant" in [str(d) for d in api.drivers()]

0 comments on commit bae14d8

Please sign in to comment.