addClass fix + unit test