Skip to content

Refactor utilities under Foundation.Process and CartonHelpers.Process and share implementations #1543

Refactor utilities under Foundation.Process and CartonHelpers.Process and share implementations

Refactor utilities under Foundation.Process and CartonHelpers.Process and share implementations #1543

Workflow file for this run

name: Build and test
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
swift-test-macos:
name: Build and test on ${{ matrix.os }} with Swift ${{ matrix.swift }}, Xcode ${{ matrix.xcode }}
timeout-minutes: 40
runs-on: ${{ matrix.os }}
strategy:
matrix:
include:
- os: macos-14
xcode: "15.4"
swift: "5.10"
- os: macos-13
xcode: "15.2"
swift: "5.9.2"
steps:
- name: Checkout the repository
uses: actions/checkout@v4
- name: Select Xcode version
run: sudo xcode-select --switch /Applications/Xcode_${{ matrix.xcode }}.app/Contents/Developer
- name: Check Swift version
run: swift --version
- name: Install dependencies for macOS
run: brew bundle
- name: Build the project
run: swift build --build-tests
- name: Run tests
run: swift test
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
swift-test-linux:
name: Build and test on Linux with Swift ${{ matrix.swift.version }}
timeout-minutes: 40
runs-on: ubuntu-22.04
strategy:
matrix:
include:
- swift:
dir: "swift-5.10-release/ubuntu2204"
version: "swift-5.10-RELEASE"
- swift:
dir: "swift-5.9.2-release/ubuntu2204"
version: "swift-5.9.2-RELEASE"
steps:
- name: Checkout the repository
uses: actions/checkout@v4
- name: Install Swift toolchain
uses: ./.github/actions/install-swift
with:
swift-dir: ${{ matrix.swift.dir }}
swift-version: ${{ matrix.swift.version }}
- name: Check Swift version
run: swift --version
- name: Install dependent packages for WebAssembly
run: >
sudo apt-get update && sudo apt-get install -y
wabt binaryen
- name: Install WebAssembly runtime
uses: bytecodealliance/actions/wasmtime/setup@v1
- name: Build the project
run: swift build --build-tests
- name: Run tests
run: swift test
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}