Skip to content

YDB tests

YDB tests #708

Workflow file for this run

name: YDB tests
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
schedule:
- cron: '18 4 * * *'
env:
CARGO_TERM_COLOR: always
CARGO_INCREMENTAL: 0
CACHE_VERSION: 1
CARGO_REGISTRIES_CRATES_IO_PROTOCOL: sparse
jobs:
tests:
strategy:
fail-fast: false
matrix:
rust_version: [ "1.56.0", "1.68.0" ]
services:
ydb:
image: cr.yandex/yc/yandex-docker-local-ydb:stable-22-5
ports:
- 2135:2135
- 2136:2136
- 8765:8765
volumes:
- /tmp/ydb_certs:/ydb_certs
env:
YDB_USE_IN_MEMORY_PDISKS: true
options: '-h localhost'
runs-on: ubuntu-20.04
steps:
- name: Install fixed rust version
uses: ATiltedTree/setup-rust@v1
with:
rust-version: ${{ matrix.rust_version }}
components: clippy
- name: Checkout
uses: actions/checkout@v2
with:
submodules: true
- name: Rust version
id: rust_version_step
run: |
rustc --version
cargo --version
echo "CARGO_INCREMENTAL=$CARGO_INCREMENTAL"
echo "::set-output name=version::$(rustc --version | cut -d ' ' -f 2)"
- name: Rust cache
uses: Swatinem/rust-cache@v2
- name: Build
run: cargo build --verbose --workspace --all-targets
- name: Linter
if: matrix.rust_version != '1.56.0'
run: |
cargo clippy --workspace --all-targets -- -D warnings
- name: Run tests
env:
YDB_CONNECTION_STRING: grpc://localhost:2136?database=/local
run: cargo test --verbose --workspace -- --include-ignored