arelastic 2.8.0 → 2.9.0
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1352e598774b8ec63e6e5840c21bdde48f6057d0863130e85589641496175f1d
|
4
|
+
data.tar.gz: 86e8f6398f27fda2b81cc7554fd22027cf7a7c985e116db498cf68dd8dd24553
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c51d28cc2d3fef1c52c6055ae1e897d988a366aaf2ac847bc1c6b07bba07ec168311ce735f527d48b7a4164aa7c85f5a73aa70ac1ec14644e2c6be9ef463fb5a
|
7
|
+
data.tar.gz: aff6d66dc806cab29a7d4e7d3a03a82ee3582acbe510d2cec8fdbb97576ed55e65fa935f783c1e1bb44338f4a19690863e9513bb0f938bdb1f6673c383a9b82a
|
@@ -1,6 +1,7 @@
|
|
1
1
|
require 'arelastic/aggregations/aggregation'
|
2
2
|
require 'arelastic/aggregations/bucket'
|
3
3
|
|
4
|
+
require 'arelastic/aggregations/cardinality'
|
4
5
|
require 'arelastic/aggregations/date_histogram'
|
5
6
|
require 'arelastic/aggregations/filter'
|
6
7
|
require 'arelastic/aggregations/filters'
|
@@ -0,0 +1,16 @@
|
|
1
|
+
require 'helper'
|
2
|
+
|
3
|
+
class Arelastic::Aggregations::CardinalityTest < Minitest::Test
|
4
|
+
def test_as_elastic
|
5
|
+
aggregation = Arelastic::Aggregations::Cardinality.new('foo', 'field' => 'name')
|
6
|
+
|
7
|
+
expected = {
|
8
|
+
"foo" => {
|
9
|
+
"cardinality" => {
|
10
|
+
"field" => "name"
|
11
|
+
}
|
12
|
+
}
|
13
|
+
}
|
14
|
+
assert_equal expected, aggregation.as_elastic
|
15
|
+
end
|
16
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: arelastic
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.9.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Matthew Higgins
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-
|
11
|
+
date: 2019-09-09 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: Build Elastic Search queries with objects
|
14
14
|
email: developer@matthewhiggins.com
|
@@ -22,6 +22,7 @@ files:
|
|
22
22
|
- lib/arelastic/aggregations.rb
|
23
23
|
- lib/arelastic/aggregations/aggregation.rb
|
24
24
|
- lib/arelastic/aggregations/bucket.rb
|
25
|
+
- lib/arelastic/aggregations/cardinality.rb
|
25
26
|
- lib/arelastic/aggregations/date_histogram.rb
|
26
27
|
- lib/arelastic/aggregations/filter.rb
|
27
28
|
- lib/arelastic/aggregations/filters.rb
|
@@ -103,6 +104,7 @@ files:
|
|
103
104
|
- lib/arelastic/sorts/sort.rb
|
104
105
|
- test/arelastic/aggregations/aggregation_test.rb
|
105
106
|
- test/arelastic/aggregations/bucket_test.rb
|
107
|
+
- test/arelastic/aggregations/cardinality_test.rb
|
106
108
|
- test/arelastic/aggregations/date_histogram_test.rb
|
107
109
|
- test/arelastic/aggregations/filter_test.rb
|
108
110
|
- test/arelastic/aggregations/filters_test.rb
|