diff --git a/all-is-cubes-content/src/template.rs b/all-is-cubes-content/src/template.rs index de9e749f9..a23696ba3 100644 --- a/all-is-cubes-content/src/template.rs +++ b/all-is-cubes-content/src/template.rs @@ -513,7 +513,7 @@ mod tests { if template != UniverseTemplate::Blank { let _ = u.get_default_character().unwrap().read().unwrap(); } - u.step(false, time::DeadlineStd::Asap); + u.step(false, time::DeadlineNt::Asap); } } } diff --git a/all-is-cubes/src/behavior.rs b/all-is-cubes/src/behavior.rs index c7c21dbd8..dd3426fcb 100644 --- a/all-is-cubes/src/behavior.rs +++ b/all-is-cubes/src/behavior.rs @@ -905,8 +905,8 @@ mod tests { }); let character = u.insert_anonymous(character); - u.step(false, time::DeadlineStd::Whenever); - u.step(false, time::DeadlineStd::Whenever); + u.step(false, time::DeadlineNt::Whenever); + u.step(false, time::DeadlineNt::Whenever); // Until we have a way to query the behavior set, the best test we can do is to // read its effects. @@ -934,7 +934,7 @@ mod tests { .count(), 1 ); - u.step(false, time::DeadlineStd::Whenever); + u.step(false, time::DeadlineNt::Whenever); assert_eq!( character .read() diff --git a/all-is-cubes/src/block/modifier/move.rs b/all-is-cubes/src/block/modifier/move.rs index a6eaba523..677d01191 100644 --- a/all-is-cubes/src/block/modifier/move.rs +++ b/all-is-cubes/src/block/modifier/move.rs @@ -340,7 +340,7 @@ mod tests { // TODO: We need a "step until idle" function, or for the UniverseStepInfo to convey how many blocks were updated / are waiting // TODO: Some tests will want to look at the partial results for _ in 0..257 { - universe.step(false, time::DeadlineStd::Whenever); + universe.step(false, time::DeadlineNt::Whenever); } checker(&space.read().unwrap(), &block); } diff --git a/all-is-cubes/src/character/exposure.rs b/all-is-cubes/src/character/exposure.rs index 6f8ec2cb3..8a153fa39 100644 --- a/all-is-cubes/src/character/exposure.rs +++ b/all-is-cubes/src/character/exposure.rs @@ -185,7 +185,7 @@ mod tests { // .fill_uniform(space.bounds().expand(FaceMap::repeat(-1)), AIR) // .unwrap(); - space.evaluate_light::(0, |_| {}); + space.evaluate_light::(0, |_| {}); space }); let mut character = Character::spawn_default(space); diff --git a/all-is-cubes/src/save/tests.rs b/all-is-cubes/src/save/tests.rs index c6bf23464..d19027672 100644 --- a/all-is-cubes/src/save/tests.rs +++ b/all-is-cubes/src/save/tests.rs @@ -749,7 +749,7 @@ fn space_light_queue_remembered() { ); // Then, when stepped, they are updated - let (_, _) = space2.step(None, Tick::arbitrary(), time::DeadlineStd::Whenever); + let (_, _) = space2.step(None, Tick::arbitrary(), time::DeadlineNt::Whenever); assert_eq!( [0, 1, 2].map(|x| space2.get_lighting([x, 0, 0]).status()), [Opaque, Visible, NoRays] diff --git a/all-is-cubes/src/space/light/tests.rs b/all-is-cubes/src/space/light/tests.rs index 17b4828ca..5243c7459 100644 --- a/all-is-cubes/src/space/light/tests.rs +++ b/all-is-cubes/src/space/light/tests.rs @@ -98,7 +98,7 @@ fn step() { assert_eq!(space.get_lighting([1, 0, 0]), PackedLight::NO_RAYS); assert_eq!(space.get_lighting([2, 0, 0]), PackedLight::NO_RAYS); - let (info, _) = space.step(None, time::Tick::arbitrary(), time::DeadlineStd::Whenever); + let (info, _) = space.step(None, time::Tick::arbitrary(), time::DeadlineNt::Whenever); assert_eq!( info.light, LightUpdatesInfo { @@ -280,7 +280,7 @@ fn disabled_lighting_does_not_update() { .light_needs_update(Cube::new(0, 0, 0), Priority::UNINIT); assert_eq!( space - .step(None, time::Tick::arbitrary(), time::DeadlineStd::Whenever) + .step(None, time::Tick::arbitrary(), time::DeadlineNt::Whenever) .0 .light, LightUpdatesInfo::default() diff --git a/all-is-cubes/src/space/tests.rs b/all-is-cubes/src/space/tests.rs index a79068ca5..b5d45ef4e 100644 --- a/all-is-cubes/src/space/tests.rs +++ b/all-is-cubes/src/space/tests.rs @@ -420,7 +420,7 @@ fn listens_to_block_changes() { // computations like reevaluation to happen during the notification process. assert_eq!(sink.drain(), vec![]); // Instead, it only happens the next time the space is stepped. - let (_, _) = space.step(None, Tick::arbitrary(), time::DeadlineStd::Whenever); + let (_, _) = space.step(None, Tick::arbitrary(), time::DeadlineNt::Whenever); // Now we should see a notification and the evaluated block data having changed. assert_eq!(sink.drain(), vec![SpaceChange::BlockEvaluation(0)]); assert_eq!(space.get_evaluated([0, 0, 0]), &new_evaluated); @@ -450,7 +450,7 @@ fn indirect_becomes_evaluation_error() { .unwrap(); // Step the space to let it notice. - let (_, _) = space.step(None, Tick::arbitrary(), time::DeadlineStd::Whenever); + let (_, _) = space.step(None, Tick::arbitrary(), time::DeadlineNt::Whenever); // Now we should see a notification and the evaluated block data having changed. assert_eq!(sink.drain(), vec![SpaceChange::BlockEvaluation(0)]); @@ -586,11 +586,11 @@ fn block_tick_action_does_not_run_paused() { let mut clock = time::Clock::new(time::TickSchedule::per_second(10), 0); // No effect when paused - _ = space.step(None, clock.advance(true), time::DeadlineStd::Whenever); + _ = space.step(None, clock.advance(true), time::DeadlineNt::Whenever); assert_eq!(space[[0, 0, 0]], vanisher); // Operation applied when unpaused - _ = space.step(None, clock.advance(false), time::DeadlineStd::Whenever); + _ = space.step(None, clock.advance(false), time::DeadlineNt::Whenever); assert_eq!(space[[0, 0, 0]], AIR); } @@ -631,7 +631,7 @@ fn block_tick_action_timing() { 99 }); - let (_info, step_txn) = space.step(None, clock.advance(false), time::DeadlineStd::Whenever); + let (_info, step_txn) = space.step(None, clock.advance(false), time::DeadlineNt::Whenever); // TODO: the block effect isn't a returned transaction yet but it perhaps should be. // This test will need reworking at that point. assert_eq!(step_txn, UniverseTransaction::default()); @@ -681,7 +681,7 @@ fn block_tick_action_conflict() { space.set(left, &modifies_px_neighbor).unwrap(); space.set(right, &modifies_nx_neighbor).unwrap(); - let (_info, step_txn) = space.step(None, clock.advance(false), time::DeadlineStd::Whenever); + let (_info, step_txn) = space.step(None, clock.advance(false), time::DeadlineNt::Whenever); assert_eq!(step_txn, UniverseTransaction::default()); assert_eq!( @@ -707,7 +707,7 @@ fn block_tick_action_conflict() { // should take effect. space.set(right, &AIR).unwrap(); - let (_info, step_txn) = space.step(None, clock.advance(false), time::DeadlineStd::Whenever); + let (_info, step_txn) = space.step(None, clock.advance(false), time::DeadlineNt::Whenever); assert_eq!(step_txn, UniverseTransaction::default()); assert_eq!(fluff_sink.drain(), vec![]); assert_eq!( diff --git a/all-is-cubes/src/universe/tests.rs b/all-is-cubes/src/universe/tests.rs index e1b44bb35..15fa578a4 100644 --- a/all-is-cubes/src/universe/tests.rs +++ b/all-is-cubes/src/universe/tests.rs @@ -330,9 +330,9 @@ fn delete_wrong_universe_fails() { fn step_time() { let mut u = Universe::new(); assert_eq!(u.session_step_time, 0); - u.step(false, time::DeadlineStd::Whenever); + u.step(false, time::DeadlineNt::Whenever); assert_eq!(u.session_step_time, 1); - u.step(true, time::DeadlineStd::Whenever); + u.step(true, time::DeadlineNt::Whenever); assert_eq!(u.session_step_time, 1); } @@ -370,13 +370,13 @@ fn universe_behavior() { dbg!(&u); assert!(u.get_any(&"foo".into()).is_none()); - u.step(false, time::DeadlineStd::Whenever); + u.step(false, time::DeadlineNt::Whenever); // After stepping, the behavior should have done its thing assert!(u.get_any(&"foo".into()).is_some()); // A further step should not fail since the behavior removed itself - u.step(false, time::DeadlineStd::Whenever); + u.step(false, time::DeadlineNt::Whenever); } #[test] @@ -393,7 +393,7 @@ fn gc_implicit() { let mut u = Universe::new(); u.insert_anonymous(BlockDef::new(AIR)); assert_eq!(1, u.iter_by_type::().count()); - u.step(false, time::DeadlineStd::Whenever); + u.step(false, time::DeadlineNt::Whenever); assert_eq!(0, u.iter_by_type::().count()); }