mirror of
https://github.com/oven-sh/bun
synced 2026-02-10 02:48:50 +00:00
* think about the future * waaaaaaaaaaa * a * testing * make it faster * fire * macos and linux * stuff * a * a * CI * buh * disable in debug * Apply formatting changes * a * a * Apply formatting changes * more review comment resolution * a * a * oh no i started writing macos code from within windows i should stop and switch devices again * rookie mistake --------- Co-authored-by: Jarred Sumner <jarred@jarredsumner.com> Co-authored-by: paperdave <paperdave@users.noreply.github.com>
91 lines
2.8 KiB
YAML
91 lines
2.8 KiB
YAML
name: C++ CI
|
|
|
|
on: [push]
|
|
|
|
jobs:
|
|
short_fuzzing:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Build fuzzers
|
|
id: build
|
|
uses: google/oss-fuzz/infra/cifuzz/actions/build_fuzzers@master
|
|
with:
|
|
oss-fuzz-project-name: "uwebsockets"
|
|
language: c++
|
|
- name: Run fuzzers
|
|
uses: google/oss-fuzz/infra/cifuzz/actions/run_fuzzers@master
|
|
with:
|
|
oss-fuzz-project-name: "uwebsockets"
|
|
language: c++
|
|
fuzz-seconds: 600
|
|
- name: Upload crash
|
|
uses: actions/upload-artifact@v4
|
|
if: failure() && steps.build.outcome == 'success'
|
|
with:
|
|
name: artifacts
|
|
path: ./out/artifacts
|
|
if-no-files-found: "error"
|
|
|
|
build_windows:
|
|
runs-on: windows
|
|
steps:
|
|
- name: Clone source
|
|
run: git clone --recursive https://github.com/uNetworking/uWebSockets.git
|
|
- name: Install libuv
|
|
run: |
|
|
vcpkg install libuv:x64-windows
|
|
cp C:\vcpkg\installed\x64-windows\bin\uv.dll uWebSockets\uv.dll
|
|
- uses: ilammy/msvc-dev-cmd@v1
|
|
- name: Build examples
|
|
run: |
|
|
cd uWebSockets
|
|
$Env:WITH_ZLIB='0'; $ENV:WITH_LTO='0'; $Env:CC='clang';
|
|
$ENV:CFLAGS='-I C:\vcpkg\installed\x64-windows\include';
|
|
$ENV:LDFLAGS='-L C:\vcpkg\installed\x64-windows\lib';
|
|
$ENV:CXX='clang++'; $ENV:EXEC_SUFFIX='.exe'; $ENV:WITH_LIBUV='1'; nmake
|
|
ls
|
|
- name: Run unit tests
|
|
run: $Env:CC='clang'; $Env:CXX='clang++'; make -C uWebSockets/tests
|
|
- name: Run smoke test
|
|
run: |
|
|
cd uWebSockets
|
|
iwr https://deno.land/x/install/install.ps1 -useb | iex
|
|
Start-Process -NoNewWindow .\Crc32
|
|
sleep 1
|
|
deno run --allow-net tests\smoke.mjs
|
|
Stop-Process -Name Crc32
|
|
|
|
build_linux:
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Clone source
|
|
run: git clone --recursive https://github.com/uNetworking/uWebSockets.git
|
|
- name: Build source
|
|
run: make -C uWebSockets
|
|
- name: List binaries
|
|
run: ls uWebSockets
|
|
- name: Install Deno
|
|
run: curl -fsSL https://deno.land/x/install/install.sh | sh
|
|
- name: Run smoke test
|
|
run: make -C uWebSockets/tests smoke
|
|
- name: Run unit tests
|
|
run: make -C uWebSockets/tests
|
|
|
|
build_osx:
|
|
runs-on: macos-latest
|
|
|
|
steps:
|
|
- name: Clone source
|
|
run: git clone --recursive https://github.com/uNetworking/uWebSockets.git
|
|
- name: Build source
|
|
run: make -C uWebSockets
|
|
- name: List binaries
|
|
run: ls uWebSockets
|
|
- name: Install Deno
|
|
run: curl -fsSL https://deno.land/x/install/install.sh | sh
|
|
- name: Run smoke test
|
|
run: make -C uWebSockets/tests smoke
|
|
- name: Run unit tests
|
|
run: make -C uWebSockets/tests
|