version: 2 jobs: core: docker: - image: rust:1 steps: - checkout - restore_cache: key: target-cache - run: rustc --version; cargo --version; rustup --version - run: rustup component add rustfmt - run: rustup component add clippy - run: cargo fmt -- --check - run: cargo test - run: cargo clippy - run: cargo bench - save_cache: key: target-cache paths: - ~/.cargo - ./target ios: macos: xcode: "10.0.0" steps: - checkout - run: command: xcodebuild test -workspace Example/StretchKit.xcworkspace -scheme StretchKit -destination 'platform=iOS Simulator,name=iPhone XR,OS=12.0' working_directory: bindings/swift js: docker: - image: circleci/rust:1-node-browsers steps: - checkout - restore_cache: key: js-target-cache - run: rustc --version; cargo --version; rustup --version - run: rustup component add rustfmt - run: rustup component add clippy - run: cargo install wasm-pack - run: command: cargo fmt -- --check working_directory: bindings/js - run: command: wasm-pack test --node working_directory: bindings/js - run: command: cargo clippy working_directory: bindings/js - save_cache: key: js-target-cache paths: - ~/.cargo - ./target android: docker: - image: rust:1 steps: - checkout - restore_cache: key: target-cache - run: rustc --version; cargo --version; rustup --version - run: rustup component add rustfmt - run: rustup component add clippy - run: command: cargo fmt -- --check working_directory: bindings/kotlin/stretch/src/main/rust - run: command: cargo test working_directory: bindings/kotlin/stretch/src/main/rust - run: command: cargo clippy working_directory: bindings/kotlin/stretch/src/main/rust - save_cache: key: target-cache paths: - ~/.cargo - ./target docs: docker: - image: circleci/node:9.11.2 steps: - checkout - restore_cache: name: Restore Yarn Package Cache key: yarn-packages-{{ checksum "docs/yarn.lock" }} - run: command: yarn install working_directory: docs - run: command: ./node_modules/.bin/gatsby build working_directory: docs - save_cache: name: Save Yarn Package Cache key: yarn-packages-{{ checksum "docs/yarn.lock" }} paths: - ~/.cache/yarn workflows: version: 2 test_all: jobs: - core - ios - js - android - docs