mirror of
https://github.com/openai/codex.git
synced 2026-10-26 18:38:47 +00:00
Add Daybreak state to the status line and terminal title (#49861)
## What changed Add a selectable `daybreak` item to the status line and terminal title, including setup previews and terminal-title validation. Display `Daybreak on` when enabled for the thread and `Daybreak off` otherwise, including during side conversations. ## Testing Add coverage for on/off rendering and side conversations, update setup preview snapshots, and verify that terminal-title diagnostics accept `daybreak`. GitOrigin-RevId: b0b7a6f0ee0a107ba4ee2d56113a5b9b6ebd1d41
This commit is contained in:
@@ -142,6 +142,7 @@ fn terminal_title_item_id(item: &str) -> Option<&'static str> {
|
||||
"total-output-tokens" => Some("total-output-tokens"),
|
||||
"thread-id" | "session-id" => Some("thread-id"),
|
||||
"fast-mode" => Some("fast-mode"),
|
||||
"daybreak" => Some("daybreak"),
|
||||
"model" | "model-name" => Some("model"),
|
||||
"model-with-reasoning" => Some("model-with-reasoning"),
|
||||
"reasoning" => Some("reasoning"),
|
||||
@@ -309,11 +310,12 @@ mod tests {
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn terminal_title_accepts_thread_usage_items() {
|
||||
fn terminal_title_accepts_configured_items() {
|
||||
let check = terminal_title_check_from_inputs(TerminalTitleInputs {
|
||||
configured_items: Some(vec![
|
||||
"thread-credits".to_string(),
|
||||
"estimated-thread-cost".to_string(),
|
||||
"daybreak".to_string(),
|
||||
]),
|
||||
cwd: PathBuf::from("/workspace/project"),
|
||||
project_root: None,
|
||||
@@ -321,11 +323,9 @@ mod tests {
|
||||
|
||||
assert_eq!(check.status, CheckStatus::Ok);
|
||||
assert_eq!(check.summary, "terminal title configured");
|
||||
assert!(
|
||||
check.details.contains(
|
||||
&"terminal title items: thread-credits, estimated-thread-cost".to_string()
|
||||
)
|
||||
);
|
||||
assert!(check.details.contains(
|
||||
&"terminal title items: thread-credits, estimated-thread-cost, daybreak".to_string()
|
||||
));
|
||||
assert!(check.issues.is_empty());
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user