MCPcopy Create free account
hub / github.com/PHPantom-dev/phpantom_lsp / static_method_override

Function static_method_override

tests/integration/code_lens.rs:465–482  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

463
464#[test]
465fn static_method_override() {
466 let backend = create_test_backend();
467 let content = r#"<?php
468class Factory {
469 public static function create(): static { return new static(); }
470}
471
472class UserFactory extends Factory {
473 public static function create(): static { return new static(); }
474}
475"#;
476 let uri = "file:///test.php";
477 let lenses = get_code_lenses(&backend, uri, content);
478 let titles = lens_titles(&lenses);
479
480 assert_eq!(titles.len(), 1);
481 assert_eq!(titles[0], "↑ Factory::create");
482}
483
484// ─── Empty File / No Classes ────────────────────────────────────────────────
485

Callers

nothing calls this directly

Calls 3

create_test_backendFunction · 0.85
get_code_lensesFunction · 0.85
lens_titlesFunction · 0.85

Tested by

no test coverage detected