You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by us...@apache.org on 2025/05/10 23:54:31 UTC

(lucene) branch main updated: Expressions: Improve test to use a fully private class or method

This is an automated email from the ASF dual-hosted git repository.

uschindler pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/lucene.git


The following commit(s) were added to refs/heads/main by this push:
     new 04126613864 Expressions: Improve test to use a fully private class or method
04126613864 is described below

commit 04126613864bd55d051b60963091c95e9df9a633
Author: Uwe Schindler <us...@apache.org>
AuthorDate: Sun May 11 01:54:21 2025 +0200

    Expressions: Improve test to use a fully private class or method
---
 .../test/org/apache/lucene/expressions/js/TestCustomFunctions.java  | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/lucene/expressions/src/test/org/apache/lucene/expressions/js/TestCustomFunctions.java b/lucene/expressions/src/test/org/apache/lucene/expressions/js/TestCustomFunctions.java
index 315b1dbd42c..84248f477d1 100644
--- a/lucene/expressions/src/test/org/apache/lucene/expressions/js/TestCustomFunctions.java
+++ b/lucene/expressions/src/test/org/apache/lucene/expressions/js/TestCustomFunctions.java
@@ -198,7 +198,8 @@ public class TestCustomFunctions extends CompilerTestCase {
     assertTrue(expected.getMessage().contains("is not static"));
   }
 
-  static double nonPublicMethod() {
+  @SuppressWarnings("unused")
+  private static double nonPublicMethod() {
     return 7;
   }
 
@@ -209,7 +210,8 @@ public class TestCustomFunctions extends CompilerTestCase {
     assertEquals(7, expr.evaluate(null), DELTA);
   }
 
-  static class NestedNotPublic {
+  @SuppressWarnings("unused")
+  private static class NestedNotPublic {
     public static double method() {
       return 41;
     }