Skip to content

Add mark to define per-test feature requirements #205

Description

@lidavidm

Instead of requiring pytest_generate_tests it would be great if we could do something more generic, like

@pytest.mark.needs_features(lambda features: features.statement_execute_schema and features.get_objects)
def test_foo(driver, conn):
    ...

# alternatively
@pytest.mark.needs_features(["statement_execute_schema", "get_objects"])
def test_foo(driver, conn):
    ...

Then we could have a generic generate_tests to handle most of these.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions