nexia_event_store 0.5.4 → 0.5.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 2cc501e9623ab03b744d5b09b6d65bb6632c3dcb
4
- data.tar.gz: 5f1a770213edd84b706d826bfb3f143a595a4ea0
3
+ metadata.gz: 75c841fd2b24716c2dbd7b9b13f5bf7a36b49245
4
+ data.tar.gz: 566d2e421c91050e0772e2ccbc5d27c03c096901
5
5
  SHA512:
6
- metadata.gz: e17c78026daaa04b99cbb9c94f4347e068fe2003912a757705432d7c79e67e20eee6987424827031f0ced5ad9802a2b77f8b3d9759d0e8eae38567e4b6695acf
7
- data.tar.gz: 68b5d31ff10d7b9ead75cb691c6ad870df1e112afe918946c3cc812e7dc45a682599dc0cbef1326ee593b86f975d8d9d3e0852b4123becec024aa305e28e68bb
6
+ metadata.gz: dfff57a2513a6ac67143e6aab4debc8e52349e81694f3956aa41383300b3d08284be7b5539284f3fcb1a09039d4020d4338fe45860e25cd4bcde329b2144b1f6
7
+ data.tar.gz: f6d785fdd24304b0b33cef67726cc7a50581c895300b41da3e3d57c4ee906914e23058b7a8542a29a0cca8842d173a5f157dbf1ce9217936bbfece606c18c7ff
@@ -27,6 +27,10 @@ module EventStore
27
27
  version(snapshot_key(fully_qualified_name: fully_qualified_name, sub_key: sub_key))
28
28
  end
29
29
 
30
+ def count
31
+ auto_rebuild_snapshot(read_raw_snapshot).count
32
+ end
33
+
30
34
  def each
31
35
  events_hash = auto_rebuild_snapshot(read_raw_snapshot)
32
36
  events_hash.inject([]) do |snapshot, (key, value)|
@@ -1,3 +1,3 @@
1
1
  module EventStore
2
- VERSION = '0.5.4'
2
+ VERSION = '0.5.5'
3
3
  end
@@ -30,6 +30,12 @@ module EventStore
30
30
  client.append events_for(AGGREGATE_ID_TWO)
31
31
  end
32
32
 
33
+ describe "#count" do
34
+ it "delegates to the snapshot hash" do
35
+ expect(client.snapshot.count).to eq(8)
36
+ end
37
+ end
38
+
33
39
  it "rebuilds a snapshot after it is deleted" do
34
40
  snapshot = client.snapshot
35
41
  client.delete_snapshot!
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nexia_event_store
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.4
4
+ version: 0.5.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Paul Saieg, John Colvin
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2015-03-24 00:00:00.000000000 Z
12
+ date: 2015-04-06 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: bundler
@@ -273,7 +273,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
273
273
  version: '0'
274
274
  requirements: []
275
275
  rubyforge_project:
276
- rubygems_version: 2.4.2
276
+ rubygems_version: 2.4.3
277
277
  signing_key:
278
278
  specification_version: 4
279
279
  summary: Ruby implementation of an EventSource (A+ES) for the Nexia Ecosystem