Skip to content

Commit 73b40a4

Browse files
fix
1 parent 1496901 commit 73b40a4

File tree

1 file changed

+12
-2
lines changed
  • codegen-core/src/main/kotlin/software/amazon/smithy/rust/codegen/core/testutil

1 file changed

+12
-2
lines changed

codegen-core/src/main/kotlin/software/amazon/smithy/rust/codegen/core/testutil/Rust.kt

+12-2
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,12 @@ private object Commands {
9797
// // cargo test --features serde-serialize serde-deserialize
9898
// ```
9999
fun cargoTest(featuresToEnable: Array<String>?): String {
100-
return func("cargo test", allFeature, enableAllFeatures)
100+
if (featuresToEnable != null) {
101+
val s = featuresToEnable.joinToString { " " }
102+
return "cargo test --features $s"
103+
}else {
104+
return "cargo test"
105+
}
101106
}
102107

103108
// enable features specified in the array
@@ -107,7 +112,12 @@ private object Commands {
107112
// // cargo check --features serde-serialize serde-deserialize
108113
// ```
109114
fun cargoCheck(featuresToEnable: Array<String>?): String {
110-
return func("cargo check", allFeature, enableAllFeatures)
115+
if (featuresToEnable != null) {
116+
val s = featuresToEnable.joinToString { " " }
117+
return "cargo check --features $s"
118+
}else {
119+
return "cargo check"
120+
}
111121
}
112122
}
113123

0 commit comments

Comments
 (0)