Skip to content

Commit

Permalink
Don't run ops::assert_index_path() doctests on non-ILP64 non-LE
Browse files Browse the repository at this point in the history
Closes #235
  • Loading branch information
nabijaczleweli committed May 20, 2023
1 parent dcf67a5 commit 39a115c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/ops/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -988,6 +988,8 @@ pub fn crate_versions(buf: &[u8]) -> Result<Vec<Semver>, Cow<'static, str>> {
/// # Examples
///
/// ```
/// # #[cfg(all(target_pointer_width="64", target_endian="little"))] // https://github.com/nabijaczleweli/cargo-update/issues/235
/// # {
/// # use cargo_update::ops::assert_index_path;
/// # use std::env::temp_dir;
/// # use std::path::Path;
Expand All @@ -998,6 +1000,7 @@ pub fn crate_versions(buf: &[u8]) -> Result<Vec<Semver>, Cow<'static, str>> {
/// // Use find_package_data() to look for packages
/// # assert_eq!(index, idx_dir);
/// # assert_eq!(assert_index_path(&cargo_dir, "https://index.crates.io/", true).unwrap(), Path::new("/ENOENT"));
/// # }
/// ```
pub fn assert_index_path(cargo_dir: &Path, registry_url: &str, sparse: bool) -> Result<PathBuf, Cow<'static, str>> {
if sparse {
Expand Down

0 comments on commit 39a115c

Please sign in to comment.