Changing alert threshold to 10% errors, and adding tests.