Refactored completion tests to support more flexible input file format