def test_write_js_to_file_writes_correct_contents_to_desired_file(self):
        contents = ["var example = function() {", "    console.log('this is an example');", "}"]
        sut.write_buffer_contents_to_file(JS_FILE, contents)
        with open(JS_FILE, "r") as f:
            self.assertEqual(f.readlines(), [line + "\n" for line in contents])
dataset/ETHPy150Open JarrodCTaylor/vim-js2coffee/tests/vim_js2coffee_tests.py/VimJS2CoffeeTests.test_write_js_to_file_writes_correct_contents_to_desired_file/original