- Login: resta solo chiave API (+ header, Bedrock). Rimossi OAuth/browser, device code, refresh/revoke su auth.openai.com, PAT, agent/workload identity, runtime agent instance, backend-client e openapi-models, workspace routing. - Rimossi: generazione immagini (ext + skill imagegen), history notes, plugin remoti (catalogo, sync, share), cyber access program, daybreak, cloud config e requirements (config_server ora fail-closed), attestation, frozen cloud skills, EMA MCP auth, Codex Apps/connettori, ricerca ospitata, header/zstd/ routing/cookie del backend Codex, fallback OPENAI_API_KEY del realtime. - Messaggi d'errore senza link a chatgpt.com. - Chiavi di config legacy accettate e ignorate; feature rimosse = Stage::Removed. - Test: cancellati solo quelli del codice rimosso; test di sicurezza (sandbox estensioni, permessi, redazione, auth storage, requirements) adattati. Restano solo fallimenti d'ambiente (code-mode-host/V8, ~/.agents). - Istruzioni di sistema invariate. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
46 lines
1.4 KiB
Rust
46 lines
1.4 KiB
Rust
use super::*;
|
|
use pretty_assertions::assert_eq;
|
|
|
|
#[test]
|
|
fn earlier_requirement_fragments_take_precedence() {
|
|
let fixture = ManagedConfigFixture::requirements("[features]\na = true\n")
|
|
.with_requirements("[features]\na = false\nb = false\n");
|
|
|
|
let merged: TomlValue = toml::from_str(
|
|
&fixture
|
|
.requirements_toml()
|
|
.expect("merge requirements")
|
|
.expect("requirements present"),
|
|
)
|
|
.expect("merged requirements parse");
|
|
|
|
assert_eq!(
|
|
merged,
|
|
toml::from_str::<TomlValue>("[features]\na = true\nb = false\n").expect("expected toml"),
|
|
);
|
|
}
|
|
|
|
#[test]
|
|
fn writes_fixture_files_as_system_layers() {
|
|
let dir = tempfile::tempdir().expect("tempdir");
|
|
let fixture = ManagedConfigFixture::requirements("allowed_approval_policies = [\"never\"]\n")
|
|
.with_config("model = \"managed\"\n");
|
|
|
|
let overrides = fixture
|
|
.loader_overrides_for_tests(dir.path())
|
|
.expect("write fixture");
|
|
|
|
let requirements_path = overrides
|
|
.system_requirements_path
|
|
.expect("requirements path");
|
|
let config_path = overrides.system_config_path.expect("config path");
|
|
assert_eq!(
|
|
std::fs::read_to_string(requirements_path).expect("read requirements"),
|
|
"allowed_approval_policies = [\"never\"]\n"
|
|
);
|
|
assert_eq!(
|
|
std::fs::read_to_string(config_path).expect("read config"),
|
|
"model = \"managed\"\n"
|
|
);
|
|
}
|