[enh] parse class and fix tests