diff --git a/.github/workflows/e2e-tests.yml b/.github/workflows/e2e-tests.yml index fa478ac6..95f764e4 100644 --- a/.github/workflows/e2e-tests.yml +++ b/.github/workflows/e2e-tests.yml @@ -38,7 +38,7 @@ jobs: - name: Verify 3.9.13 run: python __tests__/verify-python.py 3.9.13 - - name: Run with setup-python 3.9.13 + - name: Run with setup-python 3.10.11 uses: ./ with: python-version: 3.10.11 @@ -89,7 +89,56 @@ jobs: python-version: '<3.13' - name: Verify <3.13 run: python __tests__/verify-python.py 3.12 + - name: Test Raw Endpoint Access run: | curl -L https://raw.githubusercontent.com/actions/python-versions/main/versions-manifest.json | jq empty shell: bash + + verify-install-path: + name: Verify Install Path + runs-on: ${{ matrix.os }} + strategy: + matrix: + os: [windows-11-arm] + architecture: [x86, arm64] + python-version: ['3.11', '3.12', '3.13.1', '3.14.0-beta.2'] + freethreaded: ['false'] + include: + - os: windows-11-arm + architecture: x86 + python-version: '3.13.1' + freethreaded: true + - os: windows-11-arm + architecture: arm64 + python-version: '3.13.1' + freethreaded: true + - os: windows-11-arm + architecture: x86 + python-version: '3.14.0-beta.2' + freethreaded: true + - os: windows-11-arm + architecture: arm64 + python-version: '3.14.0-beta.2' + freethreaded: true + - os: windows-latest + architecture: x86 + python-version: '3.10' + freethreaded: false + + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Set up Python + uses: ./ + with: + python-version: ${{ matrix.python-version }} + architecture: ${{ matrix.architecture }} + freethreaded: ${{ matrix.freethreaded }} + + - name: Verify Install Path + shell: pwsh + run: python __tests__/verify-windows-install-path.py ` + -arch ${{ matrix.architecture }} ` + -freethreaded ${{ matrix.freethreaded }} \ No newline at end of file diff --git a/__tests__/verify_windows_install_path_user.py b/__tests__/verify_windows_install_path_user.py index 9ee8eb36..df539f99 100644 --- a/__tests__/verify_windows_install_path_user.py +++ b/__tests__/verify_windows_install_path_user.py @@ -1,9 +1,7 @@ import os import sys -def build_expected_path(architecture, freethreaded): - major = 3 - minor = 13 +def build_expected_path(architecture, freethreaded, major, minor): version_suffix = f"{major}{minor}" if architecture == "x86" and (major > 3 or (major == 3 and minor >= 10)): @@ -22,14 +20,20 @@ def build_expected_path(architecture, freethreaded): return os.path.join(base_path, "Python", f"Python{version_suffix}", "Scripts") def main(): - if len(sys.argv) != 3: - print("Usage: python verify_windows_install_path.py ") + # Expecting: -arch -freethreaded + if len(sys.argv) != 5: + print("Usage: python verify-windows-install-path.py -arch -freethreaded ") sys.exit(1) - architecture = sys.argv[1] - freethreaded = sys.argv[2] + args = dict(zip(sys.argv[1::2], sys.argv[2::2])) + architecture = args.get('-arch') + freethreaded = args.get('-freethreaded') - expected_path = build_expected_path(architecture, freethreaded) + # Get major and minor version from current Python + major = sys.version_info.major + minor = sys.version_info.minor + + expected_path = build_expected_path(architecture, freethreaded, major, minor) print(f"Expected PATH entry: {expected_path}") path_env = os.getenv("PATH", "") @@ -38,6 +42,7 @@ def main(): sys.exit(1) else: print("Correct path present in PATH") + print(f"Verified path: {expected_path}") if __name__ == "__main__": main() \ No newline at end of file