Earth’s most recent brush with asteroid danger was eight years ago, when a space rock the size of a six-story building came seemingly out of nowhere, injuring 1,200 people when it exploded over Chelyabinsk, Russia.

Now, scientists are using this month’s flyby of the infamous asteroid Apophis to test their responses to potentially hazardous space rocks, honing the fine art of planetary defense. Planetary defense focuses on identifying asteroids and comets that hang out around Earth, mapping their precise paths and seeing how their orbits compare with Earth’s.