spockframework / spockframework/spock

@Use category is not available in where-block code

Open
#1,032 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Java
Stars
3.6k
Forks
483
PR merge metrics
No merged PRs in 30d

Description

If you annotate a feature method with @Use, I'd expect the category also being applied to the where code, but this is not the case currently. You can only use it in other parts of the feature method.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the reported behavior with a feature method annotated with @Use and a where block. Trace how the category is applied in each part of the feature method, then inspect existing tests around @Use and data-driven features. Done means the category is also available in where-block code and the regression is covered by a test.

Written by the indexing model from the issue text.

Assessment

Tech stack
groovy
Domain
testing
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.