Skip to content

Commit

Permalink
Merge pull request #108 from Haehnchen/feature/typeprovider-disable
Browse files Browse the repository at this point in the history
 #107 type provider disable for PhpStorm 2023.1 support
  • Loading branch information
Haehnchen authored Mar 29, 2023
2 parents 51cc72d + c618021 commit d57daa3
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/main/resources/META-INF/plugin.xml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,9 @@
-->

<extensions defaultExtensionNs="com.jetbrains.php">
<!--
<typeProvider3 implementation="de.espend.idea.php.toolbox.type.PhpToolboxTypeProvider"/>
-->
</extensions>

<extensions defaultExtensionNs="com.intellij">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ public String getTestDataPath() {
}

public void testPhpTypeForMethods() {
// skip
if (true) return;

assertPhpReferenceResolveTo(PhpFileType.INSTANCE, "<?php\n" +
"/** @var $f \\Foo\\Bar */\n" +
"$f->foo('datetime')->for<caret>mat()",
Expand All @@ -44,6 +47,9 @@ public void testPhpTypeForMethods() {
}

public void testPhpTypeForFunctions() {
// skip
if (true) return;

assertPhpReferenceResolveTo(PhpFileType.INSTANCE, "<?php\n" +
"car('', 'datetime')->for<caret>mat()",
PlatformPatterns.psiElement(Method.class).withName("format")
Expand All @@ -56,6 +62,9 @@ public void testPhpTypeForFunctions() {
}

public void testPhpTypeForStaticMethods() {
// skip
if (true) return;

assertPhpReferenceResolveTo(PhpFileType.INSTANCE, "<?php\n" +
"\\Foo\\Bar::app('datetime')->for<caret>mat()",
PlatformPatterns.psiElement(Method.class).withName("format")
Expand All @@ -68,13 +77,19 @@ public void testPhpTypeForStaticMethods() {
}

public void testClassProvider() {
// skip
if (true) return;

assertPhpReferenceResolveTo(PhpFileType.INSTANCE, "<?php\n" +
"clazz('DateTime')->for<caret>mat()",
PlatformPatterns.psiElement(Method.class).withName("format")
);
}

public void testClassBackslash() {
// skip
if (true) return;

assertPhpReferenceResolveTo(PhpFileType.INSTANCE, "<?php\n" +
"clazz('\\DateTime')->for<caret>mat()",
PlatformPatterns.psiElement(Method.class).withName("format")
Expand Down

0 comments on commit d57daa3

Please sign in to comment.