()
| 1659 | |
| 1660 | #[test] |
| 1661 | fn test_update_config() { |
| 1662 | let temp = TestDir::new("opencode_update_config"); |
| 1663 | |
| 1664 | let patch = Config { |
| 1665 | model: Some("claude-3-opus".to_string()), |
| 1666 | ..Default::default() |
| 1667 | }; |
| 1668 | |
| 1669 | update_config(&temp.path, &patch).unwrap(); |
| 1670 | |
| 1671 | let content = fs::read_to_string(temp.path.join("opencode.json")).unwrap(); |
| 1672 | let config: Config = serde_json::from_str(&content).unwrap(); |
| 1673 | assert_eq!(config.model, Some("claude-3-opus".to_string())); |
| 1674 | } |
| 1675 | |
| 1676 | // ── YAML frontmatter parsing tests ────────────────────────────── |
| 1677 |
nothing calls this directly
no test coverage detected