tests & implementation for frame