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

Function ends_with

backend/src/http/repo_url.rs:201–207  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

199
200 #[test]
201 fn ends_with() {
202 let url = parse("https://www.dni.gov//Prelimary-Assessment-UAP-20210625.pdf?q=something");
203 assert!(url.ends_with(".pdf"));
204
205 let url = parse("https://www.dni.gov//Prelimary-Assessment-UAP-20210625.html?q=something");
206 assert!(!url.ends_with(".pdf"));
207 }
208
209 #[test]
210 fn is_pdf() {

Callers

nothing calls this directly

Calls 1

parseFunction · 0.85

Tested by

no test coverage detected