Passing writing back to js file test