Refactor and add integration test.

Move one of the AnalysisTask methods out to a decorator, and add
a proper Cucumber integration test for the percentage update
support.