-
Notifications
You must be signed in to change notification settings - Fork 14
111 lines (98 loc) · 4.13 KB
/
end-to-end-test-macos.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
106
107
108
109
110
111
name: End-to-end test on MacOS
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
merge_group:
jobs:
end-to-end-test-macos:
runs-on: ${{matrix.os}}
strategy:
fail-fast: true
matrix:
os: [macos-12]
steps:
- name: Checkout the QLever script
uses: actions/checkout@v3
with:
path: qlever-control
- name: Install locally + install dependencies needed for testing
working-directory: ${{github.workspace}}/qlever-control
run: |
python3 -m pip install --upgrade pip setuptools wheel
python3 --version
pip3 --version
pip3 show setuptools wheel
pip3 install -e .
brew install unzip expect
pip3 install flake8
# Install Clang++ 16 and make sure that it is used.
brew install llvm@16
brew install conan@2
# echo 'export PATH="/usr/local/opt/llvm@16/bin:$PATH"' >> ~/.bash_profile
# echo PATH="/usr/local/opt/llvm@16/bin:$PATH" >> $GITHUB_ENV
# echo 'export LDFLAGS="-L/usr/local/opt/llvm@16/lib -L/usr/local/opt/llvm@16/lib/c++ -Wl,-rpath,/usr/local/opt/llvm@16/lib/c++"' >> ~/.bash_profile
# echo LDFLAGS="-L/usr/local/opt/llvm@16/lib -L/usr/local/opt/llvm@16/lib/c++ -Wl,-rpath,/usr/local/opt/llvm@16/lib/c++" >> $GITHUB_ENV
# echo 'export CPPFLAGS="-I/usr/local/opt/llvm@16/include"' >> ~/.bash_profile
# echo CPPFLAGS="/usr/local/opt/llvm@16/include" >> $GITHUB_ENV
# source ~/.bash_profile
- name: Print clang version
run: clang++ --version
- name: Cache for Conan modules
uses: actions/cache@v3
env:
cache-name: conan-modules
with:
path: ~/.conan2
key: ${{matrix.os}}-${{env.cache-name}}-2
- name: Cache for QLever code and binaries
uses: actions/cache@v3
env:
cache-name: qlever-code
with:
path: ${{github.workspace}}/qlever-code
key: ${{matrix.os}}-${{env.cache-name}}
- name: Fetch or update QLever
run: |
if [ ! -d qlever-code ]; then
git clone https://github.com/ad-freiburg/qlever.git qlever-code; fi
cd qlever-code
git pull
- name: Install dependencies using Conan 1/2
working-directory: ${{github.workspace}}/qlever-code
run: |
mkdir -p build && cd $_
conan install .. -pr:b=../conanprofiles/clang-16-macos -pr:h=../conanprofiles/clang-16-macos -of=. --build=missing;
- name: Install dependencies using Conan 2/2
working-directory: ${{github.workspace}}/qlever-code
run: |
export PATH="/usr/local/opt/llvm@16/bin:$PATH"
export LDFLAGS="-L/usr/local/opt/llvm@16/lib -L/usr/local/opt/llvm@16/lib/c++ -Wl,-rpath,/usr/local/opt/llvm@16/lib/c++"
export CPPFLAGS="-I/usr/local/opt/llvm@16/include"
cmake -B build -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE="$(pwd)/build/conan_toolchain.cmake" -DUSE_PARALLEL=true -DRUN_EXPENSIVE_TESTS=false -DENABLE_EXPENSIVE_CHECKS=true -DCMAKE_CXX_COMPILER=clang++ -DADDITIONAL_COMPILER_FLAGS="-fexperimental-library" -DADDITIONAL_LINKER_FLAGS="-L$(brew --prefix llvm)/lib/c++"
- name: Compile QLever
run: |
source build/conanrun.sh
make -C build ServerMain IndexBuilderMain
- name: Check that everything is found and runs
run: |
export PATH="$PATH:$(pwd)/qlever-code/build"
source qlever-code/build/conanrun.sh
ServerMain --help > /dev/null
IndexBuilderMain --help > /dev/null
qlever
qlever help
- name: Test actions for olympics dataset, without Docker
timeout-minutes: 1
run: |
export PATH="$PATH:$(pwd)/qlever-code/build"
export QLEVER_ARGCOMPLETE_ENABLED=1
mkdir -p ${{github.workspace}}/qlever-indices/olympics.1 && cd $_
qlever setup-config olympics
qlever get-data
qlever index --system native
qlever start --system native
qlever status
qlever stop
ls -lh