yotsuba

Crates.ioyotsuba
lib.rsyotsuba
version0.0.2
sourcesrc
created_at2019-07-24 02:17:14.109403
updated_at2019-08-10 02:43:05.776283
descriptionRSpec-style testing for Rust.
homepage
repository
max_upload_size
id151202
size6,663
Reese Williams (reese)

documentation

README

Yotsuba

An RSpec-style test framework for Rust.

Build Status Download Count Version

Getting started

Yotsuba is a collection of macros and matchers that allow for quicker testing and more readable tests.

#[macro_use] extern crate yotsuba;

fn your_cool_function(num: u64) -> u64 { return num * num }

describe!(your_cool_function, {
  it!(does_what_you_think_it_does, {
    let cool_result = your_cool_function(5);
    expect!(cool_result; to equal 25)
  });

  it!(does_not_do_what_it_should_not, {
    let cool_result = your_cool_function(10);
    expect!(cool_result; to not_equal 7)
  });
});
Commit count: 0

cargo fmt