Skip to content

Conversation

@skogseth
Copy link
Contributor

@skogseth skogseth commented Oct 28, 2025

This adds some tests verifying that we accept #[cfg(..)] together with the #[test] macro.

Fixes #141

@coveralls
Copy link

coveralls commented Oct 28, 2025

Pull Request Test Coverage Report for Build 18934252348

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 30.588%

Totals Coverage Status
Change from base Build 18922077486: 0.0%
Covered Lines: 505
Relevant Lines: 1651

💛 - Coveralls

@skogseth
Copy link
Contributor Author

This should close #141, but #140 is still an option for the future.

@epage
Copy link
Collaborator

epage commented Oct 28, 2025

We'll also need tests that verify this.

Probably the safest is a #[cfg(any())] and a #[cfg(all())] test

@epage
Copy link
Collaborator

epage commented Oct 29, 2025

Feel free to clean up commits for how this should be reviewed.

It also looks like #144 introduced conflicts

@skogseth skogseth force-pushed the allow-attrs branch 2 times, most recently from 84fd435 to b0ac68e Compare October 29, 2025 19:25
@skogseth skogseth changed the title feat: Allow attributes to pass through parsing in #[test] macro fix: Add tests for accepting #[cfg(..)] Oct 30, 2025
@epage epage merged commit c989901 into assert-rs:main Oct 30, 2025
15 checks passed
@skogseth skogseth deleted the allow-attrs branch October 30, 2025 12:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Allow #[cfg] after #[test]

3 participants