frondeus / test-case

Rust procedural macro attribute for adding test cases easily
MIT License
609 stars 38 forks source link

Review possibility to add `test_case` attribute to items within `impl` blocks #91

Open luke-biel opened 2 years ago

luke-biel commented 2 years ago

As in title. Since we support using test case on free floating fn items, it would be useful to review if we can enable this functionality on impl blocks, eg.:

impl StructName {
    #[test_case("abcd" => Ok(("ab", "cd")))]
    fn parse(input: &[u8]) -> IResult<&[u8], &[u8])> {
        todo!()
    }
}

this may require extra attribute though.

AugustoFKL commented 7 months ago

@luke-biel, is anyone working on this?

Seems an interesting issue, I'd like to take it over if possible.

frondeus commented 7 months ago

I doubt that anyone is working on this. Feel free 😊

On Wed, Jan 24, 2024, 04:37 Augusto Fotino @.***> wrote:

@luke-biel https://github.com/luke-biel, is anyone working on this?

Seems an interesting issue, I'd like to take it over if possible.

— Reply to this email directly, view it on GitHub https://github.com/frondeus/test-case/issues/91#issuecomment-1907299699, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAI4UAJBQNIPBZRZQ7ZQS2DYQB6XHAVCNFSM5RJDUWMKU5DIOJSWCZC7NNSXTN2JONZXKZKDN5WW2ZLOOQ5TCOJQG4ZDSOJWHE4Q . You are receiving this because you are subscribed to this thread.Message ID: @.***>