MCPcopy Create free account
hub / github.com/FastLED/FastLED / resolve_test_include

Function resolve_test_include

ci/lint_cpp_rs/src/lib.rs:3010–3027  ·  view source on GitHub ↗
(root_prefix: &str, aggregator_rel: &str, include_path: &str)

Source from the content-addressed store, hash-verified

3008}
3009
3010fn resolve_test_include(root_prefix: &str, aggregator_rel: &str, include_path: &str) -> String {
3011 let aggregator_parent = aggregator_rel
3012 .rsplit_once('/')
3013 .map_or("", |(parent, _)| parent);
3014 let from_aggregator = if aggregator_parent.is_empty() {
3015 include_path.to_string()
3016 } else {
3017 format!("{aggregator_parent}/{include_path}")
3018 };
3019 let candidate = join_project_path(root_prefix, &from_aggregator);
3020 if candidate.exists() {
3021 return normalize_path(&path_to_string(&candidate));
3022 }
3023 normalize_path(&path_to_string(&join_project_path(
3024 root_prefix,
3025 include_path,
3026 )))
3027}
3028
3029fn collect_test_aggregation_included_files(
3030 root_prefix: &str,

Calls 5

join_project_pathFunction · 0.85
path_to_stringFunction · 0.85
normalize_pathFunction · 0.70
is_emptyMethod · 0.45
to_stringMethod · 0.45

Tested by 1