Created test for file read and write