File tree 2 files changed +6
-6
lines changed
2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -149,10 +149,10 @@ set(CARGO_TARGET_DIR "${CMAKE_BINARY_DIR}/${BUILD_DIR}/cargo/build")
149
149
150
150
if (BUILD_TESTING)
151
151
# Add CMake tests for `cargo test/clippy/fmt/doc`.
152
- add_test (NAME cargo_tests COMMAND cargo test --release --all -features --target -dir ${CARGO_TARGET_DIR} )
153
- add_test (NAME cargo_doc COMMAND cargo doc --release --all -features --target -dir ${CARGO_TARGET_DIR} )
152
+ add_test (NAME cargo_tests COMMAND cargo test --locked -- release --all -features --target -dir ${CARGO_TARGET_DIR} )
153
+ add_test (NAME cargo_doc COMMAND cargo doc --locked -- release --all -features --target -dir ${CARGO_TARGET_DIR} )
154
154
# Minimum clippy version for the incompatible_msrv lint is 1.78.0
155
- add_test (NAME cargo_clippy COMMAND cargo +1.78.0 clippy --release --all -features --target -dir ${CARGO_TARGET_DIR} -- -D warnings)
155
+ add_test (NAME cargo_clippy COMMAND cargo +1.78.0 clippy --locked -- release --all -features --target -dir ${CARGO_TARGET_DIR} -- -D warnings)
156
156
157
157
set_tests_properties (cargo_tests cargo_clippy PROPERTIES
158
158
ENVIRONMENT_MODIFICATION "${CARGO_ENV} "
Original file line number Diff line number Diff line change @@ -16,7 +16,7 @@ cd "$SOURCE_FOLDER"
16
16
# Ensure that we do see a "Compiling" in the output
17
17
# as if we do it means we have a cargo::rerun-if-changed incorrectly
18
18
function check_build_contains_compiling() {
19
- BUILD=$( cargo build --release --target-dir=" $BUILD_FOLDER " -p qml-minimal-no-cmake 2>&1 )
19
+ BUILD=$( cargo build --locked -- release --target-dir=" $BUILD_FOLDER " -p qml-minimal-no-cmake 2>&1 )
20
20
21
21
if ! echo " $BUILD " | grep -q Compiling; then
22
22
echo " cargo build is missing text 'Compiling', likely an incorrect cargo::rerun-if-changed in a build script."
@@ -27,7 +27,7 @@ function check_build_contains_compiling() {
27
27
# Ensure that we don't see any "Compiling" in the output
28
28
# as if we do it means we have a cargo::rerun-if-changed incorrectly
29
29
function check_build_no_compiling() {
30
- BUILD=$( cargo build --release --target-dir=" $BUILD_FOLDER " -p qml-minimal-no-cmake 2>&1 )
30
+ BUILD=$( cargo build --locked -- release --target-dir=" $BUILD_FOLDER " -p qml-minimal-no-cmake 2>&1 )
31
31
32
32
if echo " $BUILD " | grep -q Compiling; then
33
33
echo " cargo build contained text 'Compiling', likely an incorrect cargo::rerun-if-changed in a build script."
@@ -36,7 +36,7 @@ function check_build_no_compiling() {
36
36
}
37
37
38
38
# Build once
39
- cargo build --release --target-dir=" $BUILD_FOLDER " -p qml-minimal-no-cmake
39
+ cargo build --locked -- release --target-dir=" $BUILD_FOLDER " -p qml-minimal-no-cmake
40
40
41
41
# Build a second time
42
42
check_build_no_compiling
You can’t perform that action at this time.
0 commit comments