There has always been Oxygen on the earth, but it was not floating around free in the atmosphere as it is today (most of it still isn’t). Indeed, it is kind of strange that the earth is blanketed in a mixture of toxic, corrosive liquid (water) and equally corrosive gas (the oxygen in the atmosphere). Imagine showing up at a planet without an atmosphere or liquid water, and splashing the water and spraying the air from he earth all over that planet. Depending on the planet, it could be like throwing vinegar into a bowl of baking soda. Third grade science fair time!
In fact, this could be a test … non-gaseous planets that have previously supported earth-like life would not fizz so much under this test, but those that never had life would be likely to fizz like crazy. Or maybe I’m just crazy.
Anyway, Bad Astronomy Blog has a piece on “When did Earth’s oxygen atmosphere appear?” Check it out.