Skip to content

Commit 9367847

Browse files
leighmccullochelizabethengelman
authored andcommitted
Make builds and tests consistent (#1222)
1 parent 3a036a5 commit 9367847

File tree

2 files changed

+11
-17
lines changed

2 files changed

+11
-17
lines changed

Makefile

+10-16
Original file line numberDiff line numberDiff line change
@@ -24,36 +24,30 @@ ifeq ($(shell uname -s),Darwin)
2424
MACOS_MIN_VER = -ldflags='-extldflags -mmacosx-version-min=13.0'
2525
endif
2626

27-
# update the Cargo.lock every time the Cargo.toml changes.
28-
Cargo.lock: Cargo.toml
29-
cargo update --workspace
27+
install_rust: install
3028

31-
install_rust: Cargo.lock
32-
cargo install --path ./cmd/soroban-cli --debug
33-
cargo install --path ./cmd/crates/soroban-test/tests/fixtures/hello --root ./target --debug --quiet
34-
35-
install: install_rust
36-
37-
build_rust: Cargo.lock
38-
cargo build
29+
install:
30+
cargo install --locked --path ./cmd/soroban-cli --debug
31+
cargo install --locked --path ./cmd/crates/soroban-test/tests/fixtures/hello --root ./target --debug --quiet
3932

4033
# regenerate the example lib in `cmd/crates/soroban-spec-typsecript/fixtures/ts`
4134
build-snapshot: typescript-bindings-fixtures
4235

43-
build: build_rust
36+
build:
37+
cargo build
4438

45-
build-test-wasms: Cargo.lock
39+
build-test-wasms:
4640
cargo build --package 'test_*' --profile test-wasms --target wasm32-unknown-unknown
4741

48-
build-test: build-test-wasms install_rust
42+
build-test: build-test-wasms install
4943

5044
test: build-test
51-
cargo test
45+
cargo test
5246

5347
e2e-test:
5448
cargo test --test it -- --ignored
5549

56-
check: Cargo.lock
50+
check:
5751
cargo clippy --all-targets
5852

5953
watch:

cmd/soroban-cli/src/commands/contract/optimize.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ pub enum Error {
2323
#[error("optimization error: {0}")]
2424
OptimizationError(OptimizationError),
2525
#[cfg(not(feature = "opt"))]
26-
#[error("Must install with \"opt\" feature, e.g. `cargo install soroban-cli --features opt")]
26+
#[error("Must install with \"opt\" feature, e.g. `cargo install --locked soroban-cli --features opt")]
2727
Install,
2828
}
2929

0 commit comments

Comments
 (0)