-
Notifications
You must be signed in to change notification settings - Fork 447
105 lines (93 loc) · 3.7 KB
/
gae.yml
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
name: GraphScope GAE CI
on:
# Trigger the workflow on push or pull request,
# but only for the main branch
workflow_dispatch:
push:
branches:
- main
paths:
- 'analytical_engine/**'
- '.github/workflows/gae.yml'
- 'coordinator/gscoordinator/template/CMakeLists.template' # to verify whether java app can be successfully built when CMakeLists.template changes.
- '!analytical_engine/**.md'
pull_request:
branches:
- main
paths:
- 'analytical_engine/**'
- '.github/workflows/gae.yml'
- 'coordinator/gscoordinator/template/CMakeLists.template' # to verify whether java app can be successfully built when CMakeLists.template changes.
- '!analytical_engine/**.md'
concurrency:
group: ${{ github.repository }}-${{ github.event.number || github.head_ref || github.sha }}-${{ github.workflow }}
cancel-in-progress: true
jobs:
build-gae:
runs-on: ubuntu-20.04
if: ${{ github.repository == 'alibaba/GraphScope' }}
container:
image: registry.cn-hongkong.aliyuncs.com/graphscope/graphscope-dev:v0.18.2
steps:
- uses: actions/checkout@v3
- name: Install latest vineyard
if: false
run: |
. /home/graphscope/.graphscope_env
sudo pip3 install libclang
git clone --single-branch --depth=1 https://github.com/v6d-io/v6d.git /tmp/v6d
cd /tmp/v6d
git submodule update --init
mkdir -p build && cd build
cmake .. -DCMAKE_PREFIX_PATH=/opt/graphscope \
-DCMAKE_INSTALL_PREFIX=/opt/graphscope \
-DOPENSSL_ROOT_DIR=/opt/graphscope \
-DUSE_EXTERNAL_ETCD_LIBS=OFF \
-DBUILD_SHARED_LIBS=ON \
-DBUILD_VINEYARD_TESTS=OFF
make -j$(nproc)
sudo make install
- name: Build
env:
RUN_JAVA_TESTS: ON
run: |
# default install to "/opt/graphscope"
make analytical-java BUILD_TEST=ON NUMPROC=1
sudo make analytical-java-install
# also make coordinator and client for python test
python3 -m pip install --upgrade pip setuptools
make coordinator
- name: Run Cpp Test
env:
GRAPHSCOPE_HOME: /opt/graphscope
GS_TEST_DIR: ${{ github.workspace }}/gstest
RUN_JAVA_TESTS: ON
run: |
# download dataset
git clone -b master --single-branch --depth=1 https://github.com/7br/gstest.git ${GS_TEST_DIR}
# java maven test
cd ${GITHUB_WORKSPACE}/analytical_engine/java
mvn test -Dmaven.antrun.skip=true --quiet
version=$(cat ${GITHUB_WORKSPACE}/VERSION)
export USER_JAR_PATH=${GITHUB_WORKSPACE}/analytical_engine/java/grape-demo/target/grape-demo-${version}-shaded.jar
# for giraph test
export GIRAPH_JAR_PATH=${GITHUB_WORKSPACE}/analytical_engine/java/grape-giraph/target/grape-giraph-${version}-shaded.jar
cd ${GITHUB_WORKSPACE}/analytical_engine/build
../test/app_tests.sh --test_dir ${GS_TEST_DIR}
- name: Run Java Python Test
env:
GS_TEST_DIR: ${{ github.workspace }}/gstest
RUN_JAVA_TESTS: ON
GRAPHSCOPE_HOME: /opt/graphscope
run: |
version=$(cat ${GITHUB_WORKSPACE}/VERSION)
export USER_JAR_PATH=${GITHUB_WORKSPACE}/analytical_engine/java/grape-demo/target/grape-demo-${version}-shaded.jar
cd ${GITHUB_WORKSPACE}/python
python3 -m pytest --cov=graphscope --cov-config=.coveragerc --cov-report=xml \
--cov-report=term --exitfirst -s -v graphscope/tests/unittest/test_java_app.py
- name: Upload Coverage
uses: codecov/codecov-action@v3
continue-on-error: true
with:
file: ./python/coverage.xml
fail_ci_if_error: false