Added test for flushFrameToFile