From b77f8c93b4fd1b96cdc47feafb8b9cd25b5094ab Mon Sep 17 00:00:00 2001 From: Sam Clegg Date: Fri, 29 May 2026 11:09:35 -0700 Subject: [PATCH] Simplify `test_js_optimizer` `assertFileContents` already handles rebaselining internally. --- test/test_other.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/test/test_other.py b/test/test_other.py index 0d924f90e18a6..c90480d7bc4c2 100644 --- a/test/test_other.py +++ b/test/test_other.py @@ -3014,10 +3014,7 @@ def test_js_optimizer(self, passes, filename=None): expected_file = utils.unsuffixed(filename) + '-output.js' # test calling optimizer js = self.run_process(config.NODE_JS + [path_from_root('tools/acorn-optimizer.mjs'), filename] + passes, stdin=PIPE, stdout=PIPE).stdout - if common.EMTEST_REBASELINE: - write_file(expected_file, js) - else: - self.assertFileContents(expected_file, js) + self.assertFileContents(expected_file, js) def test_js_optimizer_huge(self): # Stress test the chunkifying code in js_optimizer.py