Skip to content

Commit 69f1c91

Browse files
pmaiHabedank Clemens
authored andcommitted
Add Python ProtoBuf build
Signed-off-by: Pierre R. Mai <pmai@pmsf.de> Signed-off-by: Habedank Clemens <qxs2704@europe.bmw.corp>
1 parent fbbcc9e commit 69f1c91

File tree

1 file changed

+23
-5
lines changed

1 file changed

+23
-5
lines changed

.github/workflows/protobuf.yml

Lines changed: 23 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ on:
66
branches: [ master ]
77

88
jobs:
9-
build-cpp-linux64:
10-
name: Build C++ Linux 64
9+
build-proto2-linux64:
10+
name: Build Proto2 Linux 64
1111

1212
runs-on: ubuntu-18.04
1313

@@ -17,6 +17,14 @@ jobs:
1717
with:
1818
submodules: true
1919

20+
- name: Setup Python
21+
uses: actions/setup-python@v2
22+
with:
23+
python-version: '3.7'
24+
25+
- name: Install Python Dependencies
26+
run: python -m pip install --upgrade pip setuptools wheel pyyaml
27+
2028
- name: Cache Dependencies
2129
id: cache-depends
2230
uses: actions/cache@v2
@@ -37,13 +45,23 @@ jobs:
3745
working-directory: protobuf-3.11.3
3846
run: sudo make install && sudo ldconfig
3947

40-
- name: Prepare Build
48+
- name: Prepare C++ Build
4149
run: mkdir build
4250

43-
- name: Configure Build
51+
- name: Configure C++ Build
4452
working-directory: build
4553
run: cmake ..
4654

47-
- name: Build
55+
- name: Build C++
4856
working-directory: build
4957
run: cmake --build . --config Release -j 4
58+
59+
- name: Build Python
60+
run: python setup.py build && python setup.py sdist
61+
62+
- name: Install Python
63+
run: python -m pip install .
64+
65+
- name: Run Python Tests
66+
run: python -m unittest discover tests
67+

0 commit comments

Comments
 (0)