MCPcopy Create free account
hub / github.com/git/git / compare_normalized_urls

Function compare_normalized_urls

t/unit-tests/u-urlmatch-normalization.c:20–33  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

18}
19
20static void compare_normalized_urls(const char *url1, const char *url2,
21 unsigned int equal)
22{
23 char *url1_norm = url_normalize(url1, NULL);
24 char *url2_norm = url_normalize(url2, NULL);
25
26 if (equal) {
27 cl_assert_equal_s(url1_norm, url2_norm);
28 } else {
29 cl_assert(strcmp(url1_norm, url2_norm) != 0);
30 }
31 free(url1_norm);
32 free(url2_norm);
33}
34
35static void check_normalized_url_length(const char *url, size_t len)
36{

Calls 1

url_normalizeFunction · 0.85

Tested by 1