-
Notifications
You must be signed in to change notification settings - Fork 24.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve test coverage for bucket and metric aggregations #22278
Labels
Comments
nik9000
added a commit
to nik9000/elasticsearch
that referenced
this issue
Jan 17, 2017
Add tests for `GlobalAggregator`, `MaxAggregator`, and `InternalMax`. Relates to elastic#22278
nik9000
added a commit
that referenced
this issue
Jan 18, 2017
Add tests for `GlobalAggregator`, `MaxAggregator`, and `InternalMax`. Relates to #22278
jimczi
added a commit
that referenced
this issue
Jan 19, 2017
Adds unit tests for the `filters` aggregation. This change also adds an helper to search and reduce any aggregator in a unit test. This is done by dividing a single searcher in sub-searcher, one for each segment. Relates #22278
jimczi
added a commit
that referenced
this issue
Jan 19, 2017
Adds unit tests for the `filters` aggregation. This change also adds an helper to search and reduce any aggregator in a unit test. This is done by dividing a single searcher in sub-searcher, one for each segment. Relates #22278
tlrx
added a commit
to tlrx/elasticsearch
that referenced
this issue
Jan 20, 2017
Adds unit tests for the date histogram aggregator. Relates elastic#22278
tlrx
added a commit
that referenced
this issue
Jan 20, 2017
Adds unit tests for the date histogram aggregator. Relates #22278
tlrx
added a commit
that referenced
this issue
Jan 20, 2017
Adds unit tests for the date histogram aggregator. Relates #22278
tlrx
added a commit
to tlrx/elasticsearch
that referenced
this issue
Jan 23, 2017
Adds unit tests for the value count aggregator. Relates elastic#22278
tlrx
added a commit
that referenced
this issue
Jan 23, 2017
Adds unit tests for the value count aggregator. Relates #22278
tlrx
added a commit
that referenced
this issue
Jan 23, 2017
Adds unit tests for the value count aggregator. Relates #22278
nik9000
added a commit
to nik9000/elasticsearch
that referenced
this issue
Jan 23, 2017
Add unit tests for `TopHitsAggregator` and convert some snippets in docs for `top_hits` aggregation to `// CONSOLE`. Relates to elastic#22278 Relates to elastic#18160
tlrx
added a commit
that referenced
this issue
Apr 19, 2017
martijnvg
added a commit
that referenced
this issue
Apr 24, 2017
tlrx
added a commit
that referenced
this issue
May 2, 2017
tlrx
added a commit
to tlrx/elasticsearch
that referenced
this issue
May 9, 2017
martijnvg
added a commit
that referenced
this issue
May 10, 2017
Also moved InternalAggregationTestCase to test-framework module in order to make use of it from other modules than core. Relates to #22278
cbuescher
added a commit
that referenced
this issue
May 12, 2017
cbuescher
added a commit
that referenced
this issue
May 16, 2017
Adding a unit test to InternalAdjecencyMatrix that extends the shared InternalAggregationTestCase that we use for testing aggregations. Relates to #22278
markharwood
added a commit
to markharwood/elasticsearch
that referenced
this issue
Jun 23, 2017
…, GlobalOrdinalsSignificantTermsAggregator.WithHash, SignificantLongTermsAggregator and SignificantStringTermsAggregator Removed integration test Relates elastic#22278
markharwood
added a commit
that referenced
this issue
Jun 23, 2017
Added unit test coverage for GlobalOrdinalsSignificantTermsAggregator, GlobalOrdinalsSignificantTermsAggregator.WithHash, SignificantLongTermsAggregator and SignificantStringTermsAggregator. Removed integration test. Relates #22278
All tasks for this ticket have now been completed 🎉 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Today there is very little unit test coverage for bucket and metric aggregations. This meta issue aim is to significantly improve that. For each aggregation we should add more unit tests for the aggregator (how it interacts with the Lucene index via
org.apache.lucene.search.Collector
that each aggregation implements), the reduce logic and serialization of the aggregation results.We should add unit tests for the following
Aggregator
implementations:ParentToChildrenAggregator
@cbuescher Add unit tests for ParentToChildAggregator #23305FilterAggregator
@colings86 Adds tests for cardinality and filter aggregations #23826FiltersAggregator
@jimczi Add unit tests for FiltersAggregator #22678GeoHashGridAggregator
@martijnvg [TEST] Add unit tests for GeoHashGridAggregator and InternalGeoHashGrid #23417GlobalAggregator
@nik9000 Improve unit test coverage of aggs #22668DateHistogramAggregator
@tlrx Add unit tests for DateHistogramAggregator #22714HistogramAggregator
@jpountz Add unit tests to histogram aggregations. #22961MissingAggregator
@jimczi Add unit tests for the missing aggregator #23895NestedAggregator
@polyfractalReverseNestedAggregator
@cbuescherRangeAggregator
(also test withDateRangeAggregationBuilder
andGeoDistanceAggregationBuilder
) @tlrx [Test] Add unit tests for Range aggregations #24569BinaryRangeAggregator
(also test withIpRangeAggregationBuilder
) @jimczi Add unit tests for BinaryRangeAggregator/InternalBinaryRange #23255DiversifiedBytesHashSamplerAggregator
,DiversifiedMapSamplerAggregator
,DiversifiedNumericSamplerAggregator
andDiversifiedOrdinalsSamplerAggregator
. @martijnvg Added unit tests for diversified sampler aggregator #23511SamplerAggregator
@nik9000 Adds unit test for sampler aggregation #23243GlobalOrdinalsSignificantTermsAggregator
,GlobalOrdinalsSignificantTermsAggregator.WithHash
,SignificantLongTermsAggregator
andSignificantStringTermsAggregator
. @markharwood Added unit test coverage for SignificantTerms #24904DoubleTermsAggregator
,GlobalOrdinalsStringTermsAggregator. LowCardinality
,GlobalOrdinalsStringTermsAggregator. WithHash
,LongTermsAggregator
andStringTermsAggregator
. @martijnvg Add more unit tests for terms aggregation #24949BestBucketsDeferringCollector
@MaineC Added unit tests for diversified sampler aggregator #23511BestDocsDeferringCollector
@polyfractal Added unit tests for diversified sampler aggregator #23511AvgAggregator
@cbuescher [Tests] Adding tests for AvgAggregator and InternalAvg #23000CardinalityAggregator
@colings86 Adds tests for cardinality and filter aggregations #23826GeoBoundsAggregator
@jimczi Add unit tests for GeoBoundsAggregator/InternalGeoBounds #23259GeoCentroidAggregator
@martijnvg Added unit test for GeoCentroidAggregator #24111MaxAggregator
@nik9000 Improve unit test coverage of aggs #22668MinAggregator
[MvG] Add base class for writing unit test for aggregations #22279TDigestPercentilesAggregator
andHDRPercentilesAggregator
@tlrx [Test] Add unit tests for HDR/TDigest PercentilesAggregators #24245TDigestPercentileRanksAggregator
andHDRPercentileRanksAggregator
. @jpountz Add unit tests to percentile ranks aggregations. #23240ScriptedMetricAggregator
@cbuescher Tests: Add unit test for InternalScriptedMetricAggregator #23404StatsAggregator
@jimcziExtendedStatsAggregator
@jimcziSumAggregator
@martijnvg [TEST] Added unit tests for sum aggs. #22954TopHitsAggregator
@nik9000 Add more tests for top_hits aggregation #22754ValueCountAggregator
@tlrx [TEST] Add unit tests for ValueCountAggregator and InternalValueCount #22741MatrixStatsAggregator
@martijnvg Add unit tests for MatrixStatsAggregator #24837We should also add tests for the following
InternalAggregation
implementations:(to test the reduce and result serialization logic)
InternalChildren
@cbuescher Tests: Add unit test for InternalChildren #23261InternalFilter
@colings86 Tests InternalSingleBucketAggregation subclasses #23388InternalFilters
@jimczi Add unit tests for FiltersAggregator #22678InternalGeoHashGrid
@martijnvg [TEST] Add unit tests for GeoHashGridAggregator and InternalGeoHashGrid #23417InternalGlobal
@nik9000 Tests InternalSingleBucketAggregation subclasses #23388InternalHistogram
@jpountz Add unit tests to histogram aggregations. #22961InternalDateHistogram
@tlrx Tests: Add unit test for InternalDateHistogram #23402InternalMissing
@MaineC Tests InternalSingleBucketAggregation subclasses #23388InternalNested
@polyfractal Tests InternalSingleBucketAggregation subclasses #23388InternalReverseNested
@cbuescher Tests InternalSingleBucketAggregation subclasses #23388InternalRange
,InternalDateRange
,InternalGeoDistance
. @tlrx [Test] Add unit tests for Range aggregations #24569InternalBinaryRange
@jimczi Add unit tests for GeoBoundsAggregator/InternalGeoBounds #23259InternalSampler
@martijnvg edada25SignificantLongTerms
andSignificantStringTerms
. @tlrx Tests: Add unit test for SignificantLongTerms and SignificantStringTerms #23428DoubleTerms
,LongTerms
,StringTerms
andUnmappedTerms
. @jpountz Add unit tests for terms aggregation objects. #23149InternalAvg
@cbuescher [Tests] Adding tests for AvgAggregator and InternalAvg #23000InternalCardinality
@colings86 Adds tests for cardinality and filter aggregations #23826InternalGeoBounds
@jimczi Add unit tests for GeoBoundsAggregator/InternalGeoBounds #23259InternalGeoCentroid
@martijnvg Added unittests for InternalGeoCentroid #24176InternalMax
@nik9000 Improve unit test coverage of aggs #22668InternalMin
@colings86 + @nik9000 Improve unit test coverage of aggs #22668InternalTDigestPercentiles
([Test] Add unit tests for InternalTDigestPercentilesTests #24090) andInternalHDRPercentiles
([Test] Add unit tests for InternalHDRPercentilesTests #24157) @tlrxInternalTDigestPercentileRanks
andInternalHDRPercentileRanks
. @jpountz Add unit tests to percentile ranks aggregations. #23240InternalScriptedMetric
@cbuescher Tests: Add unit test for InternalScriptedMetric #23330InternalStats
@jimcziInternalExtendedStats
@jimcziInternalSum
@martijnvg [TEST] Added unit tests for sum aggs. #22954InternalTopHits
@nik9000InternalValueCount
@tlrx [TEST] Add unit tests for ValueCountAggregator and InternalValueCount #22741InternalMatrixStats
@martijnvg Added unit tests for InternalMatrixStats #24559I may have forgotten some classes, so please update this issue if that is the case :)
I listed the
InternalAggregation
implementations separately fromAggregator
implementations as unit tests for each can be written in parallel by different devs. However I think for the less complex aggregations unit tests for both theInternalAggregation
implementation andAggregator
implementations can be added in the same PR.I think at least the unit tests should be added to the master branch. Backporting to 5.x branch is best effort and should only be considered if it is low hanging fruit.
I suggest that we work in the following way in order to avoid accidentally doing work twice:
Note that aggregations are tested, however due to how before the code was structured, unit testing was really difficult.
The text was updated successfully, but these errors were encountered: