adapt unit test

This commit is contained in:
Christof Petig 2021-03-24 07:37:09 +01:00
parent acba98366a
commit aa6a75808f

View File

@ -359,10 +359,10 @@ mod tests {
info!("init"); info!("init");
TradePricing::instance().print_sorted(); TradePricing::instance().print_sorted();
info!("Armor 5 {}", TradePricing::random_item(Good::Armor, 5.0)); for _ in 0..5 {
info!("Armor 5 {}", TradePricing::random_item(Good::Armor, 5.0)); if let Some(item_id) = TradePricing::random_item(Good::Armor, 5.0) {
info!("Armor 5 {}", TradePricing::random_item(Good::Armor, 5.0)); info!("Armor 5 {}", item_id);
info!("Armor 5 {}", TradePricing::random_item(Good::Armor, 5.0)); }
info!("Armor 5 {}", TradePricing::random_item(Good::Armor, 5.0)); }
} }
} }