10 releases

new 0.4.6 May 17, 2024
0.4.5 May 16, 2024
0.4.3 Dec 16, 2023
0.4.1 Dec 5, 2022
0.1.1 Feb 27, 2022

#180 in HTTP client

Download history 84/week @ 2024-01-28 613/week @ 2024-02-04 767/week @ 2024-02-11 711/week @ 2024-02-18 238/week @ 2024-02-25 634/week @ 2024-03-03 496/week @ 2024-03-10 494/week @ 2024-03-17 396/week @ 2024-03-24 514/week @ 2024-03-31 377/week @ 2024-04-07 519/week @ 2024-04-14 784/week @ 2024-04-21 1592/week @ 2024-04-28 113/week @ 2024-05-05 512/week @ 2024-05-12

3,011 downloads per month
Used in hcaptcha

MIT license

270KB
11K SLoC

mockd

Crates.io MIT licensed Build Status Rust Docs BuyMeaCoffee GitHubSponsors

Update to fakeit, a Rust port of the famous Go fakeit library with more than 130 functions.

Usage

Add mockd to the dependencies (typically dev-dependencies) in Cargo.toml


[dev-dependencies]
mockd = "0.4.6"

The contact info struct contains a phone number and email string.

    let credit_card = mockd::payment::credit_card();

    println!("Credit card: {:#?}", credit_card);

Mockd provides mock data in the following categories:

  • address
  • animal
  • beer
  • bool_rand
  • colour
  • company
  • contact
  • currency
  • datetime
  • file
  • generator
  • hacker
  • hipster
  • image
  • internet
  • job
  • language
  • log_level
  • name
  • password
  • payment
  • person
  • status_code
  • unique
  • user_agent
  • vehicle
  • words

Each category is enabled by a feature of the same name. All features can be enabled using the feature "all".

Full documentation is available at docs.rs

Dependencies

~0–610KB