-
Notifications
You must be signed in to change notification settings - Fork 2
146 lines (138 loc) · 5.13 KB
/
eosim-sanity.yml
File metadata and controls
146 lines (138 loc) · 5.13 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
name: EoSim Sanity
on:
schedule:
- cron: '0 4 * * *'
workflow_dispatch:
env:
EOSIM_VERSION: "0.1.0"
jobs:
install-validate:
name: Install & Validate (${{ matrix.os }}, Python ${{ matrix.python-version }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
python-version: ["3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python-version }}
- name: Install EoSim from source
run: |
git clone --depth 1 --branch v${{ env.EOSIM_VERSION }} https://github.com/embeddedos-org/EoSim.git /tmp/EoSim
pip install -e /tmp/EoSim
- name: Verify installation
run: |
eosim --version
eosim list
- name: Validate all platform configs
run: eosim list && eosim doctor
nested-simulation:
name: Nested Simulation (${{ matrix.platform }})
needs: install-validate
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
platform:
- x86_64-linux
- arm64-linux
- riscv64-linux
- stm32f4
- raspi4
- esp32
- nrf52
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v6
with:
python-version: "3.12"
- name: Install EoSim from source
run: |
git clone --depth 1 --branch v${{ env.EOSIM_VERSION }} https://github.com/embeddedos-org/EoSim.git /tmp/EoSim
pip install -e /tmp/EoSim
- name: Simulate ${{ matrix.platform }}
run: |
eosim run ${{ matrix.platform }} --headless --timeout 10
echo "${{ matrix.platform }}: PASSED"
nested-guest-install:
name: Guest OS Install (${{ matrix.guest }})
needs: install-validate
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- guest: Linux x86_64
platform: x86_64-linux
- guest: Linux aarch64
platform: arm64-linux
- guest: Linux riscv64
platform: riscv64-linux
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v6
with:
python-version: "3.12"
- name: Install EoSim from source
run: |
git clone --depth 1 --branch v${{ env.EOSIM_VERSION }} https://github.com/embeddedos-org/EoSim.git /tmp/EoSim
pip install -e /tmp/EoSim
- name: Boot guest and test EoSim inside
run: |
echo "=== Nested Guest: ${{ matrix.guest }} ==="
eosim run ${{ matrix.platform }} --headless --timeout 15
echo "${{ matrix.guest }}: PASSED"
windows-sanity:
name: Windows Sanity
needs: install-validate
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v6
with:
python-version: "3.12"
- name: Test EoSim on Windows
run: |
pip install "eosim @ https://github.com/embeddedos-org/EoSim/releases/download/v${{ env.EOSIM_VERSION }}/eosim-${{ env.EOSIM_VERSION }}-py3-none-any.whl"
eosim --version
eosim list && eosim doctor
eosim list
macos-sanity:
name: macOS Sanity
needs: install-validate
runs-on: macos-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v6
with:
python-version: "3.12"
- name: Test EoSim on macOS
run: |
pip install "eosim @ https://github.com/embeddedos-org/EoSim/releases/download/v${{ env.EOSIM_VERSION }}/eosim-${{ env.EOSIM_VERSION }}-py3-none-any.whl"
eosim --version
eosim list && eosim doctor
eosim list
sanity-gate:
name: EoSim Sanity Gate
if: always()
needs: [install-validate, nested-simulation, nested-guest-install, windows-sanity, macos-sanity]
runs-on: ubuntu-latest
steps:
- name: Results
run: |
echo "════════════════════════════════════════════════"
echo " EoSim Sanity Results"
echo "════════════════════════════════════════════════"
echo "Install & Validate (3 OS × 3 Py): ${{ needs.install-validate.result }}"
echo "Nested Simulation (7 platforms): ${{ needs.nested-simulation.result }}"
echo "Nested Guest Install (3 guests): ${{ needs.nested-guest-install.result }}"
echo "Windows Sanity: ${{ needs.windows-sanity.result }}"
echo "macOS Sanity: ${{ needs.macos-sanity.result }}"
echo "════════════════════════════════════════════════"
if [ "${{ needs.install-validate.result }}" != "success" ]; then
echo "❌ Install/validate failed"; exit 1
fi
echo "✅ All EoSim sanity checks passed"