Skip to content

docs: readme badges (#14) #22

docs: readme badges (#14)

docs: readme badges (#14) #22

Workflow file for this run

name: SDK
on:
push:
branches:
- main
pull_request:
workflow_dispatch:
jobs:
go-sdk:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: '^1.22'
- name: OpenMLDB cluster
run: |
docker compose -f docker-compose.yml up -d
- name: verbose services
# ensure all services is up
run: |
sleep 60
docker compose --file docker-compose.yml ps -a
- name: init test database
run: |
docker compose -f docker-compose.yml exec openmldb-ns1 /opt/openmldb/bin/openmldb --zk_cluster=openmldb-zk:2181 --zk_root_path=/openmldb --role=sql_client --cmd 'CREATE DATABASE test_db'
docker compose -f docker-compose.yml exec openmldb-ns1 /opt/openmldb/bin/openmldb --zk_cluster=openmldb-zk:2181 --zk_root_path=/openmldb --role=sql_client --cmd 'SET GLOBAL execute_mode = "online"'
- name: go test
run: go test ./... -race -covermode=atomic -coverprofile=coverage.out -v
- name: Coverage
uses: codecov/codecov-action@v4
with:
files: coverage.out
fail_ci_if_error: true
verbose: true
token: ${{ secrets.CODECOV_TOKEN }}