MCPcopy Create free account
hub / github.com/emwalker/digraph / synonym_indexes

Function synonym_indexes

backend/tests/git/topic.rs:894–919  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

892
893 #[test]
894 fn synonym_indexes() {
895 let f = Fixtures::copy("simple");
896 let repo_id = RepoId::wiki();
897 let path = parse_id("00001");
898 let date = Geotime::from(0);
899
900 let topic = f.git.fetch_topic(repo_id, &path).unwrap();
901 assert!(topic.timerange().is_none());
902
903 assert_eq!(count(&f, "A topic"), 1);
904 assert_eq!(count(&f, "1970 A topic"), 0);
905
906 UpsertTopicTimerange {
907 actor: actor(),
908 repo_id,
909 timerange: Timerange {
910 prefix_format: TimerangePrefixFormat::StartYear,
911 starts: date.into(),
912 },
913 topic_id: path,
914 }
915 .call(f.mutation(), &redis::Noop)
916 .unwrap();
917
918 assert_eq!(count(&f, "1970 A topic"), 1);
919 }
920}

Callers

nothing calls this directly

Calls 5

parse_idFunction · 0.85
actorFunction · 0.85
fetch_topicMethod · 0.45
callMethod · 0.45
mutationMethod · 0.45

Tested by

no test coverage detected