Skip to content

RFE: cases from range expression #332

@hdonnay

Description

@hdonnay

I'd like to be able to use syntax like

#[rstest]
#[case(0..256)]
fn testfunc(#[case] n: usize) {
    todo!()
}

I don't think there's another way to get a big list of tests like this, besides a lot of #[case(n)] lines or a long, written out #[values(...)] attribute.

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