Fixed 2 bugs, improve parser tests