summary refs log blame commit diff stats
path: root/rust/lucians-luscious-lasagna/tests/lucians-luscious-lasagna.rs
blob: 340d4769b45a605818818912aec3d61bfd83f666 (plain) (tree)

































                                                                                   
use lucians_luscious_lasagna::{
    elapsed_time_in_minutes, expected_minutes_in_oven, preparation_time_in_minutes,
    remaining_minutes_in_oven,
};

#[test]
fn expected_minutes_in_oven_is_correct() {
    assert_eq!(40, expected_minutes_in_oven());
}

#[test]
fn remaining_minutes_in_oven_after_fifteen_minutes() {
    assert_eq!(15, remaining_minutes_in_oven(25));
}

#[test]
fn preparation_time_in_minutes_for_one_layer() {
    assert_eq!(2, preparation_time_in_minutes(1));
}

#[test]
fn preparation_time_in_minutes_for_multiple_layers() {
    assert_eq!(8, preparation_time_in_minutes(4));
}

#[test]
fn elapsed_time_in_minutes_for_one_layer() {
    assert_eq!(32, elapsed_time_in_minutes(1, 30));
}

#[test]
fn elapsed_time_in_minutes_for_multiple_layers() {
    assert_eq!(16, elapsed_time_in_minutes(4, 8));
}