name: Rust
on: [push]
jobs:
build:
runs-on: ubuntu-latest
services:
redis:
image: redis
ports:
- 6379:6379
options: --entrypoint redis-server
steps:
- uses: actions/checkout@v1
- name: Build
run: cargo build --verbose
- name: Build (geospatial)
run: cargo build --verbose --features geospatial
- name: Run tests (with items)
run: cargo test --verbose
env:
NO_REDIS: 1
RUST_TEST_THREADS: 1
- name: Run tests (without items)
run: cargo test --verbose
env:
NO_REDIS: 1
SAMPLE_COUNT: 0
RUST_TEST_THREADS: 1
- name: Install nightly
uses: actions-rs/toolchain@v1
with:
toolchain: nightly
override: true
- name: Test nightly (with readme)
run: cargo test --verbose --features readme
env:
NO_REDIS: 1
SAMPLE_COUNT: 10
RUST_TEST_THREADS: 1