persy 1.5.0

Transactional Persistence Engine
Documentation
stages:
  - build

.shared_windows_runners:
  tags:
  - shared-windows
  - windows
  - windows-1809

nightly:
  image: "rustlang/rust:nightly"
  stage: build
  variables:
    CARGO_HOME: "cargohome"
  cache:
    paths:
      - target
      - cargohome
    key: build_nightly_cache
  before_script:
    - mkdir -p $CARGO_HOME && echo "using $CARGO_HOME to cache cargo deps"
  script:
    - env RUST_BACKTRACE=1 cargo test --all-features
  only:
    changes:
      - .gitlab-ci.yml
      - Cargo.toml
      - src/**/*
      - tests/**/*
      - benches/**/*
      - examples/**/*
  allow_failure: true

compatibility_1_70:
  image: "rust:1.70.0"
  stage: build
  variables:
    CARGO_HOME: "cargohome"
  cache:
    paths:
      - target
      - cargohome
    key: build_70_cache
  before_script:
    - mkdir -p $CARGO_HOME && echo "using $CARGO_HOME to cache cargo deps"
  script:
    - rustc --version && cargo --version      # Print version info for debugging
    - cargo test --all-features
  only:
    changes:
      - .gitlab-ci.yml
      - Cargo.toml
      - src/**/*
      - tests/**/*
      - benches/**/*
      - examples/**/*

tests_windows:
  extends:
  - .shared_windows_runners
  stage: build 
  script:
    - choco install rust -y -f
    - rustc --version
    - cargo --version
    - cargo test --all-features

build:
  image: "rust:latest"
  stage: build
  variables:
    CARGO_HOME: "cargohome"
  cache:
    paths:
      - target
      - cargohome
    key: build_cache
  before_script:
    - mkdir -p $CARGO_HOME && echo "using $CARGO_HOME to cache cargo deps"
    - cargo install cargo-tarpaulin  
  script:
    - rustc --version && cargo --version      # Print version info for debugging
    - cargo tarpaulin --all-features --out lcov
    - bash <(curl -s https://codecov.io/bash) -Z
  only:
    changes:
      - Cargo.toml
      - .gitlab-ci.yml
      - src/**/*
      - tests/**/*
      - benches/**/*
      - examples/**/*