server: init functional tests #16
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Server test scenario | |
name: Server Integration Tests | |
on: | |
workflow_dispatch: # allows manual triggering | |
push: | |
branches: | |
- master | |
- test/server-add-ci-test # FIXME remove | |
paths: ['.github/workflows/**', '**/CMakeLists.txt', '**/Makefile', '**/*.h', '**/*.hpp', '**/*.c', '**/*.cpp', '**/*.cu', '**/*.swift', '**/*.m', 'examples/server/**.*'] | |
pull_request: | |
types: [opened, synchronize, reopened] | |
paths: ['**/CMakeLists.txt', '**/Makefile', '**/*.h', '**/*.hpp', '**/*.c', '**/*.cpp', '**/*.cu', '**/*.swift', '**/*.m', 'examples/server/**.*'] | |
jobs: | |
ubuntu-latest-cmake: | |
runs-on: ubuntu-latest | |
container: | |
image: ubuntu:latest | |
ports: | |
- 8888 | |
steps: | |
- name: Clone | |
id: checkout | |
uses: actions/checkout@v3 | |
- name: Dependencies | |
id: depends | |
run: | | |
sudo apt-get update | |
sudo apt-get install build-essential | |
- name: Build | |
id: cmake_build | |
run: | | |
mkdir build | |
cd build | |
cmake .. -DCMAKE_BUILD_TYPE=Release | |
cmake --build . --config Release -j $(nproc) --target server | |
- name: Tests dependencies | |
id: test_dependencies | |
run: | | |
pip install -r examples/server/tests/requirements.txt | |
- name: Download test model | |
id: download_model | |
run: | | |
cd examples/server/tests | |
../../../scripts/hf.sh --repo ggml-org/models --file tinyllamas/stories260K.gguf | |
- name: Server Integration Tests | |
id: server_integration_test | |
run: | | |
cd examples/server/tests | |
PORT=8888 ./tests.sh |