mirror of
https://github.com/fluencelabs/wasmer
synced 2025-07-31 23:32:04 +00:00
Add rustfmt make command and CI configure
This commit is contained in:
@@ -18,6 +18,8 @@ jobs:
|
||||
- v4-test-cargo-cache-linux-{{ arch }}-{{ checksum "Cargo.lock" }}
|
||||
- run: sudo apt-get install -y cmake
|
||||
- run: make test
|
||||
- run: rustup component add rustfmt
|
||||
- run: make lint
|
||||
- save_cache:
|
||||
paths:
|
||||
- /usr/local/cargo/registry
|
||||
@@ -45,6 +47,10 @@ jobs:
|
||||
- run:
|
||||
name: Execute tests
|
||||
command: make test
|
||||
- run: rustup component add rustfmt
|
||||
- run:
|
||||
name: Execute lints
|
||||
command: make lint
|
||||
- run:
|
||||
name: Make release build
|
||||
command: |
|
||||
@@ -97,12 +103,14 @@ jobs:
|
||||
curl https://sh.rustup.rs -sSf | sh -s -- -y
|
||||
export PATH="$HOME/.cargo/bin:$PATH"
|
||||
cargo --version
|
||||
rustup component add rustfmt
|
||||
- run:
|
||||
name: Execute tests
|
||||
command: |
|
||||
export PATH="`pwd`/cmake-3.4.1-Darwin-x86_64/CMake.app/Contents/bin:$PATH"
|
||||
export PATH="$HOME/.cargo/bin:$PATH"
|
||||
make test
|
||||
make lint
|
||||
- run:
|
||||
name: Make release build
|
||||
command: |
|
||||
|
7
Makefile
7
Makefile
@@ -3,7 +3,7 @@ ifeq (test, $(firstword $(MAKECMDGOALS)))
|
||||
$(eval $(runargs):;@true)
|
||||
endif
|
||||
|
||||
.PHONY: spectests emtests clean build install
|
||||
.PHONY: spectests emtests clean build install lint precommit
|
||||
|
||||
# This will re-generate the Rust test files based on spectests/*.wast
|
||||
spectests:
|
||||
@@ -21,6 +21,11 @@ build:
|
||||
install:
|
||||
cargo install --path .
|
||||
|
||||
lint:
|
||||
cargo fmt -- --check
|
||||
|
||||
precommit: lint test
|
||||
|
||||
test:
|
||||
# We use one thread so the emscripten stdouts doesn't collide
|
||||
cargo test -- --test-threads=1 $(runargs)
|
||||
|
Reference in New Issue
Block a user