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

Function search

backend/tests/git/search.rs:130–154  ·  view source on GitHub ↗
(
        f: &Fixtures,
        topic_id: &ExternalId,
        input: &str,
        recursive: bool,
    )

Source from the content-addressed store, hash-verified

128 }
129
130 fn search(
131 f: &Fixtures,
132 topic_id: &ExternalId,
133 input: &str,
134 recursive: bool,
135 ) -> BTreeSet<SearchMatch> {
136 let fetcher = FetchDownset(f.git.clone());
137 let search = Search::parse(input).unwrap();
138 let viewer = actor();
139
140 let FindMatchesResult { matches } = FindMatches {
141 context_repo_id: RepoId::wiki(),
142 limit: 100,
143 locale: Locale::EN,
144 recursive,
145 search,
146 timespec: Timespec,
147 topic_id: topic_id.to_owned(),
148 viewer,
149 }
150 .call(&f.git, &fetcher)
151 .unwrap();
152
153 matches
154 }
155
156 #[test]
157 fn matching_topics() {

Callers 6

matching_topicsFunction · 0.85
topic_searchFunction · 0.85
combined_searchFunction · 0.85
url_searchFunction · 0.85

Calls 4

FetchDownsetClass · 0.85
parseFunction · 0.85
actorFunction · 0.85
callMethod · 0.45

Tested by

no test coverage detected