Fixed running win32 unit tests.
1 files changed, 7 insertions(+), 3 deletions(-)

M jasm/unit_test.py
M jasm/unit_test.py +7 -3
@@ 7,10 7,9 @@ def find_exe():
 	"Find exe to use in unit tests or return None if none was found."
 
 	sources = [
-		"../x64/debug-jasm/jasm.exe",
-		"../x64/release-jasm/jasm.exe",
 		"bin/debug/jasm",
 		"bin/release/jasm",
+		"../build/jasm/jasm.exe",
 		"../build/jasm/jasm"
 	]
 

          
@@ 52,8 51,13 @@ def run_test(input_path, stdout_path, st
 		else:
 			processor_arguments = ["-p", processor]
 
+		if exe.endswith(".exe"):
+			launcher = ["wine"]
+		else:
+			launcher = []
+
 		# construct command line
-		command_line = [exe] + processor_arguments + command_line_arguments + [input_path, binary_path]
+		command_line = launcher + [exe] + processor_arguments + command_line_arguments + [input_path, binary_path]
 		process = subprocess.Popen(command_line, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
 		out, err = process.communicate()
 		error_code = process.returncode