Skip to content

placeholder-literal: Scenario Outline <placeholders> incorrectly treated as missing literals #19

@nullhack

Description

@nullhack

Description

Scenario Outline placeholders like <param> in Gherkin steps are being checked by the beehave missing-literal validator as if they were regular literals that must appear in the test function body.

Expected Behavior

Placeholder delimiters <...> in Scenario Outline steps should be treated as template variables, not as literal strings. The test function receives the resolved values via Hypothesis's @given/@example decorators, so <param> should not be required in the function body.

Actual Behavior (hypothesized)

beehave check reports missing-literal: literal 'param' not found in function body for Scenario Outline examples.

Note

This issue is reported based on analysis of the source code. No reproducible test case has been confirmed with the current version. Investigation showed that the placeholder check may depend on specific feature file structure.

Potential Fix Area

The _extract_body_nodes() function in discover.py or the placeholder resolution logic may need to skip <...> delimited tokens when checking literals.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions