 (defn player-fire-times [game n]
   (last (take (inc n) (iterate #(run-player-action % :fire) game))))
 
-(defn step-times [game n]
+(defn run-zombie-actions-times [game n]
   (last (take (inc n) (iterate run-zombie-actions game))))
-
-(defn player-move [game action]
-  (-> game
-      (run-player-action action)
-      (run-zombie-actions)
-      (player-position)))
 
 (deftest test-action->coords-only-allows-directions
   (is (thrown? #?(:clj  AssertionError

(deftest test-player-does-not-move-out-of-the-world
  (are [pos action] (= pos (-> (example-game)
                               (set-player [0 4])
                               (player-move action)))
                    [0 4] :left
                    [0 4] :down))

(deftest test-player-cannot-move-on-if-a-terrain-is-blocked
  (is (= [0 1] (-> (example-game)
                   (set-player [0 1])
                   (player-move :down)))))

(deftest test-player-attack-does-not-hit-the-zombie
  (let [game (-> (example-game)

  (let [game (-> (example-game)
                 (configure-zombie-weapon [1 2] {::weapon/recharge-delay 0})
                 (configure-zombie-weapon [0 2] {::weapon/recharge-delay 0})
                 (run-zombie-actions-times 6))]
    (is (nil? (player-health game)))
    (is (nil? (player-position game)))))

