warpgrapher 0.11.2

Automate web service creation with GraphQL and Graph Databases
Documentation
name: Test

on:
  push:
    branches:
      - '**'
    tags-ignore:
      - '**'
    paths:
      - 'src/**'
      - 'tests/**'
      - 'examples/**'
      - '.github/**'

jobs:
  test:
    runs-on: ubuntu-latest

    env:
      WG_POOL_SIZE: 1
      WG_GREMLIN_HOST: localhost
      WG_GREMLIN_PORT: 8182
      WG_GREMLIN_USE_TLS: false
      WG_GREMLIN_VALIDATE_CERTS: false
      WG_GREMLIN_LONG_IDS: true
      WG_CYPHER_HOST: 127.0.0.1
      WG_CYPHER_PORT: 7687
      WG_CYPHER_USER: neo4j
      WG_CYPHER_PASS: testpass
      RUST_BACKTRACE: full
      
    steps:
    - uses: actions/checkout@v2

    - name: Cargo version
      run: cargo version
      
    - name: Cache cargo registry
      uses: actions/cache@v1
      with:
        path: ~/.cargo/registry
        key: ${{ runner.os }}-cargo-registry-${{ hashFiles('**/Cargo.lock') }}

    - name: Cache cargo index
      uses: actions/cache@v1
      with:
        path: ~/.cargo/git
        key: ${{ runner.os }}-cargo-index-${{ hashFiles('**/Cargo.lock') }}

    - name: Cache cargo build
      uses: actions/cache@v1
      with:
        path: target
        key: ${{ runner.os }}-cargo-build-target-${{ hashFiles('**/Cargo.lock') }}
    
    - name: Cache cargo audit
      uses: actions/cache@v1
      with:
        path: rustbins
        key: cargo-audit
 
    - name: Check Featureless Build
      run: cargo check
      
    - name: Check Gremlin Build
      run: cargo check --features gremlin

    - name: Check Cypher Build
      run: cargo check --features cypher

    - name: Check Examples
      run: cargo check --examples --features cypher

    - name: Install Clippy
      run: rustup component add clippy

    - name: Run Linter
      run: cargo clippy --all-targets --all-features -- -D warnings

    - name: Start gremlin database
      run: docker run --rm -d --name gremlin -p 8182:8182 tinkerpop/gremlin-server:latest
      
    - name: Start neo4j database
      run: docker run --rm -d --name neo4j -e NEO4J_AUTH="neo4j/testpass" -p 7474:7474 -p 7687:7687 neo4j:4.1

    - name: Run Tests (All Features)
      run: cargo test --all-features -- --test-threads=1

    - name: Stop neo4j database
      run: docker rm -f neo4j

    - name: Stop gremlin database
      run: docker rm -f gremlin