()
| 1607 | |
| 1608 | #[test] |
| 1609 | fn test_init_vault() { |
| 1610 | let dir = tempdir().unwrap(); |
| 1611 | let repo = Repository::init(dir.path()).unwrap(); |
| 1612 | |
| 1613 | // Vault should not exist yet |
| 1614 | assert!(!repo.has_vault().unwrap()); |
| 1615 | assert!(!repo.vault_dir().exists()); |
| 1616 | |
| 1617 | // Initialize vault |
| 1618 | repo.init_vault().unwrap(); |
| 1619 | |
| 1620 | // Vault should now exist |
| 1621 | assert!(repo.has_vault().unwrap()); |
| 1622 | assert!(repo.vault_dir().exists()); |
| 1623 | |
| 1624 | // Subdirectories should exist |
| 1625 | assert!(repo.vault_dir().join("goals").exists()); |
| 1626 | assert!(repo.vault_dir().join("memory").exists()); |
| 1627 | assert!(repo.vault_dir().join("skills").exists()); |
| 1628 | assert!(repo.vault_dir().join("intents").exists()); |
| 1629 | assert!(repo.vault_dir().join("scratch").exists()); |
| 1630 | } |
| 1631 | |
| 1632 | #[test] |
| 1633 | fn test_ensure_vault_initializes_once() { |
nothing calls this directly
no test coverage detected