Moved parsing to separate file. Some incorrect input tests.