Skip to content

Test

Test #4394

Workflow file for this run

name: Platform Run Validation
on:
workflow_dispatch:
jobs:
# Validate that the UI can be installed and ran across all platforms
validate_service_starts:
name: Validate
strategy:
fail-fast: false
matrix:
os: [macos-12, macos-13, macos-14, macos-15]
node-version: [18.x, 20.x, 22.x]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- run: npm ci
- run: npm run build:server
- run: npm run lint
- run: npm run test
# remove dev deps
- run: npm clean-install --production
# test hb-service
- run: node dist/bin/hb-service.js -v
- if: runner.os == 'Linux'
name: Run hb-service install (Linux)
run: |
sudo npm link
sudo npm install -g homebridge
sudo hb-service install --user homebridge --group `id -gn`
sleep 30
- if: runner.os == 'macOS'
name: Run hb-service install (macOS)
run: |
sudo npm link
sudo npm install -g homebridge
sudo hb-service install
sleep 30
- if: runner.os == 'Windows'
name: Run hb-service install (Windows)
run: |
npm link
npm install -g homebridge
hb-service install
Start-Sleep -s 30
- name: Test hb-service install
run: node dist/bin/hb-service.js status --port 8581
- if: runner.os == 'macOS'
name: Run hb-service update-node
run: |
sudo hb-service update-node 18
node dist/bin/hb-service.js status --port 8581
sudo hb-service update-node 20
node dist/bin/hb-service.js status --port 8581
sudo hb-service update-node 22
node dist/bin/hb-service.js status --port 8581
- name: View Errors
if: ${{ failure() }}
run: |
node dist/bin/hb-service.js view
exit 1