simplify and update tests