Files
nxnative-easy/scripts/tests/test_desktop_localization.py
T
Erick Sanchez e7bb0e27a0 Default the desktop app and README to English with a Spanish language option
Persist the interface language, translate app-owned labels and dialogs immediately, preserve raw build diagnostics, and replace unverified device and account claims with precise preparation and compatibility wording. Add English and Spanish READMEs and localization regression coverage.
2026-10-26 11:24:52 -06:00

17 lines
717 B
Python

"""Run the same language preference and text model used by the desktop app."""
from pathlib import Path
import subprocess
import sys
import tempfile
import unittest
ROOT=Path(__file__).resolve().parents[2]
@unittest.skipUnless(sys.platform=='darwin','requires Swift Foundation')
class DesktopLocalization(unittest.TestCase):
def test_language_model(self):
with tempfile.TemporaryDirectory() as tmp:
exe=Path(tmp)/'languages'
subprocess.run(['xcrun','swiftc',str(ROOT/'desktop/NxNativeEasy/Localization.swift'),
str(ROOT/'desktop/NxNativeEasy/tests/localization_check.swift'),'-o',str(exe)],check=True)
subprocess.run([str(exe)],check=True)