apache / lucene

Apache Lucene open-source search software
https://lucene.apache.org/
Apache License 2.0
2.63k stars 1.02k forks source link

Refactor TopGroups.merge tests [LUCENE-9042] #10084

Open asfimport opened 4 years ago

asfimport commented 4 years ago

This task proposes a refactoring of the test coverage for the TopGroups.merge method implemented in #10053. For now it will cover only 3 main cases. 

  1. Merging to empty TopGroups
  2. Merging a TopGroups with scores and a TopGroups without scores (currently broken because of #10039 bug) 
  3. Merging two TopGroups with scores.

I'm planning to increase the coverage testing also invalid inputs but I would do that in a separate PR to keep the code readable.


Migrated from LUCENE-9042 by Diego Ceccarelli, updated Feb 15 2020 Attachments: LUCENE-9042.patch Linked issues:

asfimport commented 4 years ago

Lucene/Solr QA (migrated from JIRA)

-1 overall
Vote Subsystem Runtime Comment
Prechecks
+1 test4tests 0m 0s The patch appears to include 1 new or modified test files.
master Compile Tests
+1 compile 0m 15s master passed
Patch Compile Tests
+1 compile 0m 17s the patch passed
-1 javac 0m 17s lucene_grouping generated 32 new + 108 unchanged - 0 fixed = 140 total (was 108)
+1 Release audit (RAT) 0m 17s the patch passed
+1 Check forbidden APIs 0m 17s the patch passed
+1 Validate source patterns 0m 17s the patch passed
Other Tests
+1 unit 0m 20s grouping in the patch passed.
2m 24s
Subsystem Report/Notes
JIRA Issue LUCENE-9042
JIRA Patch URL https://issues.apache.org/jira/secure/attachment/12985639/LUCENE-9042.patch
Optional Tests compile javac unit ratsources checkforbiddenapis validatesourcepatterns
uname Linux lucene1-us-west 4.15.0-54-generic #58-Ubuntu SMP Mon Jun 24 10:55:24 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build tool ant
Personality /home/jenkins/jenkins-slave/workspace/PreCommit-LUCENE-Build/sourcedir/dev-tools/test-patch/lucene-solr-yetus-personality.sh
git revision master / 550c7296b6f
ant version: Apache Ant(TM) version 1.10.5 compiled on March 28 2019
Default Java LTS
javac https://builds.apache.org/job/PreCommit-LUCENE-Build/226/artifact/out/diff-compile-javac-lucene_grouping.txt
Test Results https://builds.apache.org/job/PreCommit-LUCENE-Build/226/testReport/
modules C: lucene/grouping U: lucene/grouping
Console output https://builds.apache.org/job/PreCommit-LUCENE-Build/226/console
Powered by Apache Yetus 0.7.0 http://yetus.apache.org

This message was automatically generated.

asfimport commented 4 years ago

Diego Ceccarelli (migrated from JIRA)

patch updated to fix the javac warnings. 

asfimport commented 4 years ago

Lucene/Solr QA (migrated from JIRA)

-1 overall
Vote Subsystem Runtime Comment
Prechecks
+1 test4tests 0m 0s The patch appears to include 1 new or modified test files.
master Compile Tests
+1 compile 0m 16s master passed
Patch Compile Tests
+1 compile 0m 17s the patch passed
-1 javac 0m 17s lucene_grouping generated 4 new + 108 unchanged - 0 fixed = 112 total (was 108)
+1 Release audit (RAT) 0m 17s the patch passed
-1 Check forbidden APIs 0m 17s Check forbidden APIs check-forbidden-apis failed
-1 Validate source patterns 0m 17s Check forbidden APIs check-forbidden-apis failed
Other Tests
+1 unit 0m 23s grouping in the patch passed.
1m 55s
Subsystem Report/Notes
JIRA Issue LUCENE-9042
JIRA Patch URL https://issues.apache.org/jira/secure/attachment/12985735/LUCENE-9042.patch
Optional Tests compile javac unit ratsources checkforbiddenapis validatesourcepatterns
uname Linux lucene1-us-west 4.15.0-54-generic #58-Ubuntu SMP Mon Jun 24 10:55:24 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build tool ant
Personality /home/jenkins/jenkins-slave/workspace/PreCommit-LUCENE-Build/sourcedir/dev-tools/test-patch/lucene-solr-yetus-personality.sh
git revision master / 068b6babac3
ant version: Apache Ant(TM) version 1.10.5 compiled on March 28 2019
Default Java LTS
javac https://builds.apache.org/job/PreCommit-LUCENE-Build/228/artifact/out/diff-compile-javac-lucene_grouping.txt
Check forbidden APIs https://builds.apache.org/job/PreCommit-LUCENE-Build/228/artifact/out/patch-check-forbidden-apis-lucene.txt
Validate source patterns https://builds.apache.org/job/PreCommit-LUCENE-Build/228/artifact/out/patch-check-forbidden-apis-lucene.txt
Test Results https://builds.apache.org/job/PreCommit-LUCENE-Build/228/testReport/
modules C: lucene/grouping U: lucene/grouping
Console output https://builds.apache.org/job/PreCommit-LUCENE-Build/228/console
Powered by Apache Yetus 0.7.0 http://yetus.apache.org

This message was automatically generated.

asfimport commented 4 years ago

Lucene/Solr QA (migrated from JIRA)

-1 overall
Vote Subsystem Runtime Comment
Prechecks
+1 test4tests 0m 0s The patch appears to include 1 new or modified test files.
master Compile Tests
+1 compile 0m 15s master passed
Patch Compile Tests
+1 compile 0m 17s the patch passed
-1 javac 0m 17s lucene_grouping generated 3 new + 108 unchanged - 0 fixed = 111 total (was 108)
+1 Release audit (RAT) 0m 17s the patch passed
+1 Check forbidden APIs 0m 17s the patch passed
+1 Validate source patterns 0m 17s the patch passed
Other Tests
+1 unit 0m 20s grouping in the patch passed.
2m 17s
Subsystem Report/Notes
JIRA Issue LUCENE-9042
JIRA Patch URL https://issues.apache.org/jira/secure/attachment/12986358/LUCENE-9042.patch
Optional Tests compile javac unit ratsources checkforbiddenapis validatesourcepatterns
uname Linux lucene1-us-west 4.15.0-54-generic #58-Ubuntu SMP Mon Jun 24 10:55:24 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build tool ant
Personality /home/jenkins/jenkins-slave/workspace/PreCommit-LUCENE-Build/sourcedir/dev-tools/test-patch/lucene-solr-yetus-personality.sh
git revision master / f98555854cb
ant version: Apache Ant(TM) version 1.10.5 compiled on March 28 2019
Default Java LTS
javac https://builds.apache.org/job/PreCommit-LUCENE-Build/236/artifact/out/diff-compile-javac-lucene_grouping.txt
Test Results https://builds.apache.org/job/PreCommit-LUCENE-Build/236/testReport/
modules C: lucene/grouping U: lucene/grouping
Console output https://builds.apache.org/job/PreCommit-LUCENE-Build/236/console
Powered by Apache Yetus 0.7.0 http://yetus.apache.org

This message was automatically generated.

asfimport commented 4 years ago

Lucene/Solr QA (migrated from JIRA)

-1 overall
Vote Subsystem Runtime Comment
Prechecks
+1 test4tests 0m 0s The patch appears to include 1 new or modified test files.
master Compile Tests
+1 compile 0m 20s master passed
Patch Compile Tests
+1 compile 0m 20s the patch passed
-1 javac 0m 20s lucene_grouping generated 3 new + 108 unchanged - 0 fixed = 111 total (was 108)
+1 Release audit (RAT) 0m 20s the patch passed
+1 Check forbidden APIs 0m 20s the patch passed
+1 Validate source patterns 0m 20s the patch passed
Other Tests
+1 unit 0m 21s grouping in the patch passed.
4m 42s
Subsystem Report/Notes
JIRA Issue LUCENE-9042
JIRA Patch URL https://issues.apache.org/jira/secure/attachment/12986537/LUCENE-9042.patch
Optional Tests compile javac unit ratsources checkforbiddenapis validatesourcepatterns
uname Linux lucene2-us-west.apache.org 4.4.0-112-generic #135-Ubuntu SMP Fri Jan 19 11:48:36 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
Build tool ant
Personality /home/jenkins/jenkins-slave/workspace/PreCommit-LUCENE-Build/sourcedir/dev-tools/test-patch/lucene-solr-yetus-personality.sh
git revision master / 312431b
ant version: Apache Ant(TM) version 1.9.6 compiled on July 20 2018
Default Java LTS
javac https://builds.apache.org/job/PreCommit-LUCENE-Build/237/artifact/out/diff-compile-javac-lucene_grouping.txt
Test Results https://builds.apache.org/job/PreCommit-LUCENE-Build/237/testReport/
modules C: lucene/grouping U: lucene/grouping
Console output https://builds.apache.org/job/PreCommit-LUCENE-Build/237/console
Powered by Apache Yetus 0.7.0 http://yetus.apache.org

This message was automatically generated.

asfimport commented 4 years ago

Lucene/Solr QA (migrated from JIRA)

+1 overall
Vote Subsystem Runtime Comment
Prechecks
+1 test4tests 0m 0s The patch appears to include 1 new or modified test files.
master Compile Tests
+1 compile 0m 15s master passed
Patch Compile Tests
+1 compile 0m 17s the patch passed
+1 javac 0m 17s the patch passed
+1 Release audit (RAT) 0m 17s the patch passed
+1 Check forbidden APIs 0m 17s the patch passed
+1 Validate source patterns 0m 17s the patch passed
Other Tests
+1 unit 0m 28s grouping in the patch passed.
2m 34s
Subsystem Report/Notes
JIRA Issue LUCENE-9042
JIRA Patch URL https://issues.apache.org/jira/secure/attachment/12987392/LUCENE-9042.patch
Optional Tests compile javac unit ratsources checkforbiddenapis validatesourcepatterns
uname Linux lucene1-us-west 4.15.0-54-generic #58-Ubuntu SMP Mon Jun 24 10:55:24 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build tool ant
Personality /home/jenkins/jenkins-slave/workspace/PreCommit-LUCENE-Build/sourcedir/dev-tools/test-patch/lucene-solr-yetus-personality.sh
git revision master / f71c2c8e922
ant version: Apache Ant(TM) version 1.10.5 compiled on March 28 2019
Default Java LTS
Test Results https://builds.apache.org/job/PreCommit-LUCENE-Build/240/testReport/
modules C: lucene/grouping U: lucene/grouping
Console output https://builds.apache.org/job/PreCommit-LUCENE-Build/240/console
Powered by Apache Yetus 0.7.0 http://yetus.apache.org

This message was automatically generated.