diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 218796192..11d8699e4 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -17,7 +17,12 @@ jobs: matrix: os: [windows, ubuntu, macos] python: ["3.6", "3.7", "3.8", "3.9", "3.10"] - platform: [x64] + platform: [x64, x86] + exclude: + - os: ubuntu + platform: x86 + - os: macos + platform: x86 steps: - name: Set Environment on macOS @@ -67,6 +72,7 @@ jobs: run: pytest --runtime mono - name: Python Tests (.NET Core) + if: ${{ matrix.platform == 'x64' }} run: pytest --runtime netcore - name: Python Tests (.NET Framework) @@ -77,7 +83,7 @@ jobs: run: dotnet test --runtime any-${{ matrix.platform }} src/python_tests_runner/ - name: Perf tests - if: ${{ matrix.python == '3.8' }} + if: ${{ (matrix.python == '3.8') && (matrix.platform == 'x64') }} run: | pip install --force --no-deps --target src/perf_tests/baseline/ pythonnet==2.5.2 dotnet test --configuration Release --runtime any-${{ matrix.platform }} --logger "console;verbosity=detailed" src/perf_tests/ diff --git a/src/runtime/Native/NativeTypeSpec.cs b/src/runtime/Native/NativeTypeSpec.cs index c57bd9363..8b84df536 100644 --- a/src/runtime/Native/NativeTypeSpec.cs +++ b/src/runtime/Native/NativeTypeSpec.cs @@ -10,7 +10,7 @@ struct NativeTypeSpec : IDisposable public readonly StrPtr Name; public readonly int BasicSize; public readonly int ItemSize; - public readonly TypeFlags Flags; + public readonly int Flags; public IntPtr Slots; public NativeTypeSpec(TypeSpec spec) @@ -20,7 +20,7 @@ public NativeTypeSpec(TypeSpec spec) this.Name = new StrPtr(spec.Name, Encoding.UTF8); this.BasicSize = spec.BasicSize; this.ItemSize = spec.ItemSize; - this.Flags = spec.Flags; + this.Flags = (int)spec.Flags; unsafe { diff --git a/tests/conftest.py b/tests/conftest.py index 99ee07f2f..89db46eca 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -86,7 +86,11 @@ def pytest_configure(config): else: domain_tests_dir = os.path.join(os.path.dirname(__file__), "domain_tests") bin_path = os.path.join(domain_tests_dir, "bin") - check_call(["dotnet", "build", domain_tests_dir, "-o", bin_path]) + build_cmd = ["dotnet", "build", domain_tests_dir, "-o", bin_path] + is_64bits = sys.maxsize > 2**32 + if not is_64bits: + build_cmd += ["/p:Prefer32Bit=True"] + check_call(build_cmd)