You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@netbeans.apache.org by "junichi11 (via GitHub)" <gi...@apache.org> on 2023/03/22 17:29:00 UTC

[GitHub] [netbeans] junichi11 opened a new pull request, #5701: Fix being shown incorrect documentation #4494

junichi11 opened a new pull request, #5701:
URL: https://github.com/apache/netbeans/pull/5701

   - https://github.com/apache/netbeans/issues/4494
   - Add a new test method for checking documentation when a `QueryType` is `DOCUMENTATION` to `CslTestBase`
   - If `QueryType` is `DOCUMENTATION`, get a whole identifier as a prefix
   - Add unit tests
   
   ### Example
   ```php
   <?php
   
   /**
    * function gh4494.
    *
    * @return void
    */
   function gh4494(): void {
       
   }
   
   /**
    * function gh4494_aa().
    *
    * @return void
    */
   function gh4494_aa(): void {
       
   }
   
   /**
    * function gh4494_aa_bb().
    *
    * @return void
    */
   function gh4494_aa_bbb(): void {
       
   }
   
   /**
    * function gh4494_aa_bb_cc().
    *
    * @return void
    */
   function gh4494_aa_bb_cc(): void {
       
   }
   
   gh4494_aa_bb_cc();
   
   ```
   #### Before:
   
   ![nb-php-4494-before](https://user-images.githubusercontent.com/738383/226986882-e47b7bf3-1b67-4ee0-b336-dec771607281.gif)
   
   #### After:
   
   ![nb-php-4494-after](https://user-images.githubusercontent.com/738383/226986903-33303dac-ba4d-4370-ac1b-fb64ceb2da89.gif)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] junichi11 commented on pull request #5701: Fix being shown incorrect documentation #4494

Posted by "junichi11 (via GitHub)" <gi...@apache.org>.
junichi11 commented on PR #5701:
URL: https://github.com/apache/netbeans/pull/5701#issuecomment-1483739425

   Increased spec versions.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] junichi11 commented on pull request #5701: Fix being shown incorrect documentation #4494

Posted by "junichi11 (via GitHub)" <gi...@apache.org>.
junichi11 commented on PR #5701:
URL: https://github.com/apache/netbeans/pull/5701#issuecomment-1483758384

   I'll re-run it :)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] junichi11 commented on pull request #5701: Fix being shown incorrect documentation #4494

Posted by "junichi11 (via GitHub)" <gi...@apache.org>.
junichi11 commented on PR #5701:
URL: https://github.com/apache/netbeans/pull/5701#issuecomment-1483736726

   Will increase it late :) Thank you!


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] junichi11 commented on a diff in pull request #5701: Fix being shown incorrect documentation #4494

Posted by "junichi11 (via GitHub)" <gi...@apache.org>.
junichi11 commented on code in PR #5701:
URL: https://github.com/apache/netbeans/pull/5701#discussion_r1145186468


##########
ide/csl.api/test/unit/src/org/netbeans/modules/csl/api/test/CslTestBase.java:
##########
@@ -3062,8 +3062,12 @@ public boolean isCaseSensitive() {
     }
 
     public void checkCompletionDocumentation(final String file, final String caretLine, final boolean includeModifiers, final String itemPrefix) throws Exception {
+        checkCompletionDocumentation(file, caretLine, includeModifiers, itemPrefix, QueryType.COMPLETION);
+    }
+
+    public void checkCompletionDocumentation(final String file, final String caretLine, final boolean includeModifiers, final String itemPrefix, QueryType queryType) throws Exception {
         // TODO call TestCompilationInfo.setCaretOffset!
-        final QueryType type = QueryType.COMPLETION;
+        final QueryType type = queryType;

Review Comment:
   @sdedic I would like to test the cc documentation when the query type is `DOCUMENTATION`. Can we add this test method to `CslTestBase`?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] junichi11 commented on pull request #5701: Fix being shown incorrect documentation #4494

Posted by "junichi11 (via GitHub)" <gi...@apache.org>.
junichi11 commented on PR #5701:
URL: https://github.com/apache/netbeans/pull/5701#issuecomment-1483483919

   @tmysik Could you please have a look at this? If there is no problem, let's merge it :) Thank you!


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] tmysik commented on pull request #5701: Fix being shown incorrect documentation #4494

Posted by "tmysik (via GitHub)" <gi...@apache.org>.
tmysik commented on PR #5701:
URL: https://github.com/apache/netbeans/pull/5701#issuecomment-1483723992

   @junichi11 @sdedic 
   
   Don't we need to increase version of the `csl.api` module? Or in tests, this is not needed? 🤔 
   
   If not, feel free to merge.
   
   Thanks.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] sdedic commented on a diff in pull request #5701: Fix being shown incorrect documentation #4494

Posted by "sdedic (via GitHub)" <gi...@apache.org>.
sdedic commented on code in PR #5701:
URL: https://github.com/apache/netbeans/pull/5701#discussion_r1147516296


##########
ide/csl.api/test/unit/src/org/netbeans/modules/csl/api/test/CslTestBase.java:
##########
@@ -3062,8 +3062,12 @@ public boolean isCaseSensitive() {
     }
 
     public void checkCompletionDocumentation(final String file, final String caretLine, final boolean includeModifiers, final String itemPrefix) throws Exception {
+        checkCompletionDocumentation(file, caretLine, includeModifiers, itemPrefix, QueryType.COMPLETION);
+    }
+
+    public void checkCompletionDocumentation(final String file, final String caretLine, final boolean includeModifiers, final String itemPrefix, QueryType queryType) throws Exception {
         // TODO call TestCompilationInfo.setCaretOffset!
-        final QueryType type = QueryType.COMPLETION;
+        final QueryType type = queryType;

Review Comment:
   Definitely



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] tmysik commented on pull request #5701: Fix being shown incorrect documentation #4494

Posted by "tmysik (via GitHub)" <gi...@apache.org>.
tmysik commented on PR #5701:
URL: https://github.com/apache/netbeans/pull/5701#issuecomment-1483757733

   I cannot easily check it, I am on my phone only 😅


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] tmysik commented on pull request #5701: Fix being shown incorrect documentation #4494

Posted by "tmysik (via GitHub)" <gi...@apache.org>.
tmysik commented on PR #5701:
URL: https://github.com/apache/netbeans/pull/5701#issuecomment-1483757386

   The failing check can hardly be related, right?
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] junichi11 commented on a diff in pull request #5701: Fix being shown incorrect documentation #4494

Posted by "junichi11 (via GitHub)" <gi...@apache.org>.
junichi11 commented on code in PR #5701:
URL: https://github.com/apache/netbeans/pull/5701#discussion_r1148098256


##########
ide/csl.api/test/unit/src/org/netbeans/modules/csl/api/test/CslTestBase.java:
##########
@@ -3062,8 +3062,12 @@ public boolean isCaseSensitive() {
     }
 
     public void checkCompletionDocumentation(final String file, final String caretLine, final boolean includeModifiers, final String itemPrefix) throws Exception {
+        checkCompletionDocumentation(file, caretLine, includeModifiers, itemPrefix, QueryType.COMPLETION);
+    }
+
+    public void checkCompletionDocumentation(final String file, final String caretLine, final boolean includeModifiers, final String itemPrefix, QueryType queryType) throws Exception {
         // TODO call TestCompilationInfo.setCaretOffset!
-        final QueryType type = QueryType.COMPLETION;
+        final QueryType type = queryType;

Review Comment:
   Thank you!



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] tmysik commented on pull request #5701: Fix being shown incorrect documentation #4494

Posted by "tmysik (via GitHub)" <gi...@apache.org>.
tmysik commented on PR #5701:
URL: https://github.com/apache/netbeans/pull/5701#issuecomment-1483998196

   Great! Merging then...
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] tmysik merged pull request #5701: Fix being shown incorrect documentation #4494

Posted by "tmysik (via GitHub)" <gi...@apache.org>.
tmysik merged PR #5701:
URL: https://github.com/apache/netbeans/pull/5701


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] junichi11 commented on pull request #5701: Fix being shown incorrect documentation #4494

Posted by "junichi11 (via GitHub)" <gi...@apache.org>.
junichi11 commented on PR #5701:
URL: https://github.com/apache/netbeans/pull/5701#issuecomment-1483941643

   All checks are green :)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists