test(e2e): turn subtitle providers off for health
The seed enables OpenSubtitles and the e2e daemon has no credentials for it, so the health report is degraded by design. The test is about the core upstreams. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
4bfd3ba7ad
commit
9d67c44649
@@ -30,6 +30,31 @@ async fn daemon_runs_against_fakes_and_a_real_qbittorrent() {
|
||||
let daemon = Daemon::spawn(&prowlarr.url(), &tmdb.url(), &qbittorrent_url()).await;
|
||||
let base = daemon.base_url();
|
||||
|
||||
// The seed enables OpenSubtitles, and this daemon has no credentials for
|
||||
// it, which the health report rightly calls degraded. Nothing here is
|
||||
// about subtitles, so turn the providers off.
|
||||
let client = reqwest::Client::new();
|
||||
let mut settings: serde_json::Value = client
|
||||
.get(format!("{base}/api/settings/subtitles"))
|
||||
.send()
|
||||
.await
|
||||
.expect("read subtitle settings")
|
||||
.json()
|
||||
.await
|
||||
.expect("subtitle settings json");
|
||||
settings["providers_enabled"] = serde_json::json!([]);
|
||||
let saved = client
|
||||
.put(format!("{base}/api/settings/subtitles"))
|
||||
.json(&settings)
|
||||
.send()
|
||||
.await
|
||||
.expect("save subtitle settings");
|
||||
assert!(
|
||||
saved.status().is_success(),
|
||||
"{}",
|
||||
saved.text().await.unwrap_or_default()
|
||||
);
|
||||
|
||||
let health = daemon.health().await;
|
||||
assert_eq!(health["status"], "ok", "health report: {health}");
|
||||
assert_eq!(health["prowlarr"]["status"], "ok");
|
||||
|
||||
Reference in New Issue
Block a user