Correct line number for extract task
make ExtractTaskTest more robust

Asserting line numbers means that when the source changes the line
numbers need to change in the test cases. This is quite fragile causing
unrelated changes to cause this test case to fail. Converted to _not_
expect specific line numbers.