refactor class name validation
fix specs