Added tests with pattern
Refactored abstract parser test