-
Notifications
You must be signed in to change notification settings - Fork 0
160 lines (156 loc) · 5.49 KB
/
Copy pathhost-tests.yml
File metadata and controls
160 lines (156 loc) · 5.49 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
147
148
149
150
151
152
153
154
155
156
157
158
159
160
name: Host Tests
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
host-tests:
runs-on: ubuntu-latest
steps:
- name: Checkout Serial
uses: actions/checkout@v4
- name: Checkout ESPressio Command 0.4.0
uses: actions/checkout@v4
with:
repository: Flowduino/ESPressio-Command
ref: 0.4.0
path: deps/ESPressio-Command
- name: Checkout ESPressio Observable 3.0.1
uses: actions/checkout@v4
with:
repository: Flowduino/ESPressio-Observable
ref: 3.0.1
path: deps/ESPressio-Observable
- name: Checkout ESPressio Serializable 0.10.2
uses: actions/checkout@v4
with:
repository: Flowduino/ESPressio-Serializable
ref: 0.10.2
path: deps/ESPressio-Serializable
- name: Configure
run: >-
cmake -S tests -B build
-DESPRESSIO_COMMAND_INCLUDE_DIR="$GITHUB_WORKSPACE/deps/ESPressio-Command/src"
-DESPRESSIO_OBSERVABLE_INCLUDE_DIR="$GITHUB_WORKSPACE/deps/ESPressio-Observable/src"
-DESPRESSIO_SERIALIZABLE_INCLUDE_DIR="$GITHUB_WORKSPACE/deps/ESPressio-Serializable/src"
- name: Build
run: cmake --build build --parallel
- name: Test
run: ctest --test-dir build --output-on-failure
esp32-observable-monitors:
runs-on: ubuntu-latest
steps:
- name: Checkout Serial
uses: actions/checkout@v4
with:
path: project/ESPressio-Serial
- name: Checkout ESPressio Observable 3.0.1
uses: actions/checkout@v4
with:
repository: Flowduino/ESPressio-Observable
ref: 3.0.1
path: project/dependencies/ESPressio-Observable
- name: Checkout ESPressio Units 0.2.3
uses: actions/checkout@v4
with:
repository: Flowduino/ESPressio-Units
ref: 0.2.3
path: project/dependencies/ESPressio-Units
- name: Checkout ESPressio Timing 2.2.4
uses: actions/checkout@v4
with:
repository: Flowduino/ESPressio-Timing
ref: 2.2.4
path: project/dependencies/ESPressio-Timing
- name: Checkout ESPressio Threads 3.1.4
uses: actions/checkout@v4
with:
repository: Flowduino/ESPressio-Threads
ref: 3.1.4
path: project/dependencies/ESPressio-Threads
- name: Checkout ESPressio Serializable 0.10.2
uses: actions/checkout@v4
with:
repository: Flowduino/ESPressio-Serializable
ref: 0.10.2
path: project/dependencies/ESPressio-Serializable
- name: Checkout ESPressio Event 6.0.0
uses: actions/checkout@v4
with:
repository: Flowduino/ESPressio-Event
ref: 6.0.0
path: project/dependencies/ESPressio-Event
- name: Checkout ESPressio Command 0.4.0
uses: actions/checkout@v4
with:
repository: Flowduino/ESPressio-Command
ref: 0.4.0
path: project/dependencies/ESPressio-Command
- name: Checkout ESPressio Security 0.3.0
uses: actions/checkout@v4
with:
repository: Flowduino/ESPressio-Security
ref: 0.3.0
path: project/dependencies/ESPressio-Security
- name: Checkout ESPressio Sockets 0.6.0
uses: actions/checkout@v4
with:
repository: Flowduino/ESPressio-Sockets
ref: 0.6.0
path: project/dependencies/ESPressio-Sockets
- name: Checkout ESPressio ESP-Now 0.6.0
uses: actions/checkout@v4
with:
repository: Flowduino/ESPressio-ESP-Now
ref: 0.6.0
path: project/dependencies/ESPressio-ESP-Now
- uses: actions/setup-python@v5
with:
python-version: '3.x'
- name: Install PlatformIO
run: pip install platformio
- name: Create monitor compile project
shell: bash
run: |
mkdir -p project/compile/src
cat > project/compile/platformio.ini <<'EOF'
[env:esp32]
platform = espressif32
board = esp32dev
framework = arduino
build_flags =
-std=gnu++17
-frtti
-I../dependencies/ESPressio-Command/src
-I../dependencies/ESPressio-Security/src
-I../dependencies/ESPressio-Sockets/src
-I../dependencies/ESPressio-ESP-Now/src
build_unflags =
-std=gnu++11
-fno-rtti
lib_ldf_mode = deep+
lib_deps =
../dependencies/ESPressio-Observable
../dependencies/ESPressio-Units
../dependencies/ESPressio-Timing
../dependencies/ESPressio-Threads
../dependencies/ESPressio-Serializable
../dependencies/ESPressio-Event
../ESPressio-Serial
EOF
cat > project/compile/src/main.cpp <<'EOF'
#include <Arduino.h>
#include <WiFi.h>
#include <ESPressio_CommandMonitor.hpp>
#include <ESPressio_SecurityMonitor.hpp>
#include <ESPressio_SocketWorkerMonitor.hpp>
#include <ESPressio_SocketSecuritySessionMonitor.hpp>
#include <ESPressio_ESPNowTransportMonitor.hpp>
#include <ESPressio_EventMonitor.hpp>
#include <event/ESPressio_EventMonitorPayloadSafety.hpp>
void setup() {}
void loop() {}
EOF
- name: Compile ESP32 Observable and Event monitors
run: pio run -d project/compile