Refactor of Frame class, additional tests