Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: private doctests #3012

Merged
merged 9 commits into from
Jun 21, 2023
Merged

feat: private doctests #3012

merged 9 commits into from
Jun 21, 2023

Conversation

aatifsyed
Copy link
Contributor

@aatifsyed aatifsyed commented Jun 19, 2023

forest/src/lib.rs

Lines 58 to 67 in bba9455

/// These items are semver-exempt, and exist for forest author use only
// We want to have doctests, but don't want our internals to be public because:
// - We don't want to be concerned with library compat
// (We want our cargo semver to be _for the command line_).
// - We don't want to mistakenly export items which we never actually use.
//
// So we re-export the relevant items and test with `cargo test --doc --features doctest-private`
#[cfg(feature = "doctest-private")]
#[doc(hidden)]
pub mod doctest_private {

  • Do we want a different feature name? e.g __doctest-private?
  • Do we want to use #[cfg(forest_filecoin_private)] instead of features?
    • Less public facing

@aatifsyed aatifsyed mentioned this pull request Jun 19, 2023
11 tasks
@aatifsyed aatifsyed changed the title Make most of forest private Private doctests Jun 19, 2023
src/libp2p_bitswap/mod.rs Outdated Show resolved Hide resolved
@aatifsyed aatifsyed enabled auto-merge (squash) June 21, 2023 08:45
@aatifsyed aatifsyed changed the title Private doctests feat: private doctests Jun 21, 2023
@aatifsyed aatifsyed merged commit 93f493f into main Jun 21, 2023
@aatifsyed aatifsyed deleted the aatifsyed/one-crate-visibility branch June 21, 2023 09:28
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.

4 participants