Skip to content

Commit 783775e

Browse files
authored
Merge pull request #2764 from lann/fix-more-factors-tests
Fix more factors tests
2 parents 566a44c + 859ff47 commit 783775e

File tree

8 files changed

+20
-181
lines changed

8 files changed

+20
-181
lines changed

Cargo.lock

Lines changed: 1 addition & 52 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

crates/factor-outbound-http/Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,14 @@ http = "1.1.0"
1010
http-body-util = "0.1"
1111
hyper = "1.4.1"
1212
reqwest = { version = "0.11", features = ["gzip"] }
13-
rustls = "0.23"
13+
rustls = { version = "0.23", default-features = false, features = ["ring", "std"] }
1414
spin-factor-outbound-networking = { path = "../factor-outbound-networking" }
1515
spin-factors = { path = "../factors" }
1616
spin-telemetry = { path = "../telemetry" }
1717
spin-world = { path = "../world" }
1818
terminal = { path = "../terminal" }
1919
tokio = { version = "1", features = ["macros", "rt"] }
20-
tokio-rustls = "0.26"
20+
tokio-rustls = { version = "0.26", default-features = false, features = ["logging", "tls12"] }
2121
tracing = { workspace = true }
2222
wasmtime = { workspace = true }
2323
wasmtime-wasi = { workspace = true }

crates/factor-outbound-networking/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ anyhow = "1"
99
futures-util = "0.3"
1010
http = "1.1.0"
1111
ipnet = "2.9.0"
12-
rustls = "0.23"
12+
rustls = { version = "0.23", default-features = false, features = ["ring", "std", "tls12"] }
1313
rustls-pemfile = { version = "2.1.2", optional = true }
1414
rustls-pki-types = "1.7.0"
1515
serde = { version = "1", features = ["derive"] }

crates/runtime-config/src/lib.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -173,8 +173,7 @@ impl<'a> TomlResolver<'a> {
173173
// Prefer explicitly provided state directory, then take from toml.
174174
self.state_dir
175175
.or_else(from_toml)
176-
.map(PathBuf::from)
177-
.map(std::fs::canonicalize)
176+
.map(std::path::absolute)
178177
.transpose()
179178
}
180179

examples/spin-timer/Cargo.lock

Lines changed: 2 additions & 122 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/bin/spin.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,10 @@ async fn _main() -> anyhow::Result<()> {
7373
}
7474
}
7575

76-
SpinApp::from_arg_matches(&matches)?.run(cmd).await
76+
SpinApp::from_arg_matches(&matches)?
77+
.run(cmd)
78+
.await
79+
.inspect_err(|err| tracing::debug!(?err))
7780
}
7881

7982
fn print_error_chain(err: anyhow::Error) {

tests/integration.rs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -341,8 +341,13 @@ mod integration_tests {
341341
app_type: SpinAppType::None,
342342
},
343343
ServicesConfig::none(),
344-
|_| Ok(()),
344+
|env| {
345+
// Since this test asserts exact stderr output, disable logging
346+
env.set_env_var("RUST_LOG", "off");
347+
Ok(())
348+
},
345349
)?;
350+
346351
let expected = r#"Error: Couldn't find trigger executor for local app "spin.toml"
347352
348353
Caused by:

0 commit comments

Comments
 (0)