## Module publish

Source
Expand description

Helpers for testing `cargo package` / `cargo publish`

## §Example

    validate_upload(
        r#"
        {
          "authors": [],
          "badges": {},
          "categories": [],
          "deps": [],
          "description": "foo",
          "documentation": null,
          "features": {},
          "homepage": null,
          "keywords": [],
          "license": "MIT",
          "license_file": null,
          "links": null,
          "name": "foo",
          "readme": null,
          "readme_file": null,
          "repository": null,
          "rust_version": null,
          "vers": "0.0.1"
          }
        "#,
        "foo-0.0.1.crate",
        &["Cargo.lock", "Cargo.toml", "Cargo.toml.orig", "src/main.rs"],
    );

## Functions§

_validate_upload 🔒
create_index_line 🔒
read_le_u32 🔒
read_new_post 🔒
split_index_features 🔒
validate_alt_upload
  Check the `cargo publish` API call to the alternative test registry
validate_crate_contents
  Checks the contents of a `.crate` file.
validate_crate_contents_ 🔒
validate_upload
  Check the `cargo publish` API call
validate_upload_with_contents
  Check the `cargo publish` API call, with file contents
write_to_index 🔒