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

Function test_require_once_mixed_forms

tests/unit/composer.rs:587–603  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

585
586#[test]
587fn test_require_once_mixed_forms() {
588 let content = concat!(
589 "<?php\n",
590 "/**\n",
591 " * Main include file for working with the trustly-client-php code.\n",
592 " */\n",
593 "\n",
594 "require_once('Trustly/exceptions.php');\n",
595 "require_once('Trustly/Data/data.php');\n",
596 "require_once 'Trustly/Api/api.php';\n",
597 );
598 let paths = extract_require_once_paths(content);
599 assert_eq!(paths.len(), 3);
600 assert_eq!(paths[0], "Trustly/exceptions.php");
601 assert_eq!(paths[1], "Trustly/Data/data.php");
602 assert_eq!(paths[2], "Trustly/Api/api.php");
603}
604
605#[test]
606fn test_require_once_skips_dynamic_expressions() {

Callers

nothing calls this directly

Calls 1

Tested by

no test coverage detected