()
| 164 | |
| 165 | #[test] |
| 166 | fn no_orphans() { |
| 167 | let f = Fixtures::copy("simple"); |
| 168 | let url = valid_url(); |
| 169 | let repo_id = RepoId::wiki(); |
| 170 | let link_id = url.id().unwrap(); |
| 171 | assert!(!f.git.exists(repo_id, &link_id).unwrap()); |
| 172 | |
| 173 | f.upsert_link(repo_id, &url, None, None); |
| 174 | |
| 175 | f.fetch_link(repo_id, &link_id, |link| { |
| 176 | assert_eq!(link.parent_topics.len(), 1); |
| 177 | let topic = link.parent_topics.iter().next().unwrap(); |
| 178 | assert_eq!(topic.id, ExternalId::root_topic()); |
| 179 | }); |
| 180 | } |
| 181 | |
| 182 | #[test] |
| 183 | fn updates_are_idempotent() { |
nothing calls this directly
no test coverage detected