# Path: tests/utils.py
# def assert_outcomes(
#     result: RunResult,
#     passed: int = 0,
#     skipped: int = 0,
#     failed: int = 0,
#     errors: int = 0,
#     xpassed: int = 0,
#     xfailed: int = 0,
# ) -> None:
#     """Compatibility function for result.assert_outcomes"""
#     result.assert_outcomes(
#         errors=errors, passed=passed, skipped=skipped, failed=failed, xpassed=xpassed, xfailed=xfailed
#     )


import textwrap
from tests.utils import assert_outcomes



def test_scenario_not_found(testdir, pytest_params):
    """Test the situation when scenario is not found."""
    testdir.makefile(
        ".feature",
        not_found=textwrap.dedent(
            """\
            Feature: Scenario is not found

            """
        ),
    )
    testdir.makepyfile(
        textwrap.dedent(
            """\
        import re
        import pytest
        from pytest_bdd import parsers, given, then, scenario

        @scenario("not_found.feature", "NOT FOUND")
        def test_not_found():
            pass

        """
        )
    )
    result = testdir.runpytest_subprocess(*pytest_params)


# Path: tests/utils.py
# def assert_outcomes(
#     result: RunResult,
#     passed: int = 0,
#     skipped: int = 0,
#     failed: int = 0,
#     errors: int = 0,
#     xpassed: int = 0,
#     xfailed: int = 0,
# ) -> None:
#     """Compatibility function for result.assert_outcomes"""
#     result.assert_outcomes(
#         errors=errors, passed=passed, skipped=skipped, failed=failed, xpassed=xpassed, xfailed=xfailed
#     )


# Path: tests/feature/test_scenario.py
import textwrap
from tests.utils import assert_outcomes




def test_scenario_not_found(testdir, pytest_params):
    """Test the situation when scenario is not found."""
    testdir.makefile(
        ".feature",
        not_found=textwrap.dedent(
            """\
            Feature: Scenario is not found

            """
        ),
    )
    testdir.makepyfile(
        textwrap.dedent(
            """\
        import re
        import pytest
        from pytest_bdd import parsers, given, then, scenario

        @scenario("not_found.feature", "NOT FOUND")
        def test_not_found():
            pass

        """
        )
    )
    result = testdir.runpytest_subprocess(*pytest_params)


    assert_outcomes(result, errors=1)