Skip to content

ci(core): run tests on both macOS and Linux#626

Open
simonklee wants to merge 7 commits intoanomalyco:mainfrom
simonklee:ci-linu
Open

ci(core): run tests on both macOS and Linux#626
simonklee wants to merge 7 commits intoanomalyco:mainfrom
simonklee:ci-linu

Conversation

@simonklee
Copy link
Collaborator

Add matrix strategy for build core to run tests on ubuntu-latest in addition to macos-latest. Since it's a GH Actions change i have no idea if it works or fails a random way 😉

@simonklee
Copy link
Collaborator Author

Core - Build and TestExpected — Waiting for status to be reported

... guess i need to change the gate or add a new one.

@kommander
Copy link
Collaborator

I was wondering if we could re-use a similar setup as we have for the release CI flow, building the native libs once, then load the artifacts in a matrix, because for the release we use a cross compiled version, then the typescript tests would run with the cross compiled version on different platforms as well.

The native tests can be run built and run per platform. Cross compiling once could slightly improve the run duration as well I think.

But mainly to actually test the cross compiled binaries, to be close to what we would release. WDYT?

Add matrix strategy for build core to run tests on ubuntu-latest
in addition to macos-latest.
@simonklee
Copy link
Collaborator Author

simonklee commented Feb 4, 2026

I was wondering if we could re-use a similar setup as we have for the release CI flow, building the native libs once, then load the artifacts in a matrix, because for the release we use a cross compiled version, then the typescript tests would run with the cross compiled version on different platforms as well.

The native tests can be run built and run per platform. Cross compiling once could slightly improve the run duration as well I think.

But mainly to actually test the cross compiled binaries, to be close to what we would release. WDYT?

I looked more at the current pipelines and there are a couple ways you could go, but for testing core native i think you need compile on that test binary anyway so cross compiling doesn't help here.

I ended up with this

build (macos-latest)
├── Cross-compile all platforms
└── Upload artifacts
        │
        ▼
test (matrix)
├── macos-latest (darwin-arm64)
│   ├── Download artifacts
│   ├── Run native tests
│   └── Run TS tests
│
└── ubuntu-latest (linux-x64)
    ├── Download artifacts
    ├── Run native tests
    └── Run TS tests
        │
        ▼
build-complete (gate)

Split the build workflow into three parallel jobs: cross-compiling native
libraries once on macOS, running Zig native tests on more platforms, and running
TypeScript tests with cross compiled artifacts.
@simonklee

This comment was marked as outdated.

```
build (macos-latest)
├── Cross-compile all platforms
└── Upload artifacts
        │
        ▼
test (matrix)
├── macos-latest (darwin-arm64)
│   ├── Download artifacts
│   ├── Run native tests
│   └── Run TS tests
│
└── ubuntu-latest (linux-x64)
    ├── Download artifacts
    ├── Run native tests
    └── Run TS tests
        │
        ▼
build-complete (gate)
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants