From 8c4bd25179fdad7d1c385bc6a2d698120664be06 Mon Sep 17 00:00:00 2001 From: Sam Clegg Date: Mon, 20 Jul 2026 11:49:34 -0700 Subject: [PATCH] [test] Remove duplicate emmake declaration. NFC Split out from #27215 --- test/test_other.py | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/test/test_other.py b/test/test_other.py index 0e4b57d05d036..013acbe10e384 100644 --- a/test/test_other.py +++ b/test/test_other.py @@ -38,6 +38,7 @@ EMBUILDER, EMCMAKE, EMCONFIGURE, + EMMAKE, NON_ZERO, PYTHON, TEST_ROOT, @@ -127,7 +128,6 @@ write_file, ) -emmake = exe_path_from_root('emmake') emconfig = exe_path_from_root('em-config') emsize = exe_path_from_root('emsize') empath_split = exe_path_from_root('empath-split') @@ -1149,7 +1149,7 @@ def test_pkg_config_packages(self): ('sdl', '1.2.15'), ] for package, version in packages: - out = self.run_process([emmake, 'pkg-config', '--modversion', package], stdout=PIPE).stdout + out = self.run_process([EMMAKE, 'pkg-config', '--modversion', package], stdout=PIPE).stdout self.assertContained(version, out) @requires_pkg_config @@ -1157,9 +1157,9 @@ def test_pkg_config_packages(self): def test_pkg_config_ports(self): # Use bullet here because it is part of the MINIMAL set of tasks in embuilder. self.run_process([EMBUILDER, 'build', 'bullet']) - out = self.run_process([emmake, 'pkg-config', '--list-all'], stdout=PIPE).stdout + out = self.run_process([EMMAKE, 'pkg-config', '--list-all'], stdout=PIPE).stdout self.assertContained('bullet', out) - out = self.run_process([emmake, 'pkg-config', '--cflags', 'bullet'], stdout=PIPE).stdout + out = self.run_process([EMMAKE, 'pkg-config', '--cflags', 'bullet'], stdout=PIPE).stdout self.assertContained('-sUSE_BULLET', out) @parameterized({ @@ -6457,11 +6457,11 @@ def check(what, args, fail=True, expect=''): assert ('is a helper for' in output.stderr) == fail assert ('Typical usage' in output.stderr) == fail self.assertContained(expect, output.stdout) - check(emmake, []) + check(EMMAKE, []) check(EMCONFIGURE, []) - check(emmake, ['--version']) + check(EMMAKE, ['--version']) check(EMCONFIGURE, ['--version']) - check(emmake, ['make'], fail=False) + check(EMMAKE, ['make'], fail=False) check(EMCONFIGURE, ['configure'], fail=False) check(EMCONFIGURE, ['./configure'], fail=False) check(EMCMAKE, ['cmake'], fail=False) @@ -6471,7 +6471,7 @@ def check(what, args, fail=True, expect=''): print(os.environ.get('CROSS_COMPILE')) ''') check(EMCONFIGURE, [PYTHON, 'test.py'], expect=path_from_root('em'), fail=False) - check(emmake, [PYTHON, 'test.py'], expect=path_from_root('em'), fail=False) + check(EMMAKE, [PYTHON, 'test.py'], expect=path_from_root('em'), fail=False) create_file('test.py', ''' import os @@ -6488,7 +6488,7 @@ def test_emmake_python(self): # simulates a configure/make script that looks for things like CC, AR, etc., and which we should # not confuse by setting those vars to something containing `python X` as the script checks for # the existence of an executable. - self.run_process([emmake, PYTHON, test_file('emmake/make.py')]) + self.run_process([EMMAKE, PYTHON, test_file('emmake/make.py')]) @crossplatform @no_windows('sdl2-config is a shell script and cannot run on windows') @@ -6504,7 +6504,7 @@ def test_sdl2_config(self): stdout=PIPE, stderr=PIPE).stdout self.assertContained(expected, out) print('via emmake') - out = self.run_process([emmake, 'sdl2-config'] + args, stdout=PIPE, stderr=PIPE).stdout + out = self.run_process([EMMAKE, 'sdl2-config'] + args, stdout=PIPE, stderr=PIPE).stdout self.assertContained(expected, out) def test_module_onexit(self):