ruby_event_store 0.14.0 → 0.15.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
  SHA1:
3
- metadata.gz: 7d71ec6a5d4c85e551b036dda5abca24e8bddc1c
4
- data.tar.gz: 65666ce24c97b6818a2881a8ce543c4571b88192
3
+ metadata.gz: cc38dbcd5bae737fd45df10476c8de92bf427273
4
+ data.tar.gz: 8ff7c06dfefc9599a289e38233b0975c3b41e67f
5
5
  SHA512:
6
- metadata.gz: cf14a4789d7f4194598b39a8a09ad91f3baca78f6976792499a02476186b76c40a1059e12f926254e1075acc34da7b7a2f1147bea7d8a8f069f9c97e897146ba
7
- data.tar.gz: f3014bb612918f1e39a68d719705faf4a9a6227c901883978ea5414135f2fc47c30e33afebaab07b7e718a0394bb5cdeeda3d6165b94d0679aebead526c9ceac
6
+ metadata.gz: 9729e9074b157dbc10142d5af71e041c403d849100067c26d508271a98ef88feedc442f5b04098b074cd397e5b3d2997e7da41888b9e3eba260aa77ff49fcd42
7
+ data.tar.gz: 977fe81f3373b02b8f7e6ed1f499c51f4a9267c559233eb84c0eaac7f351f222971fe29bf7f44f6138f55a96c522dccce58a7a12775ddf51d914c8d5c3263921
@@ -1,3 +1,5 @@
1
+ Further changes can be tracked at [releases page](https://github.com/RailsEventStore/rails_event_store/releases).
2
+
1
3
  ### 0.14.0 (21.08.2017)
2
4
 
3
5
  * Change: Add lint for 3rd party implementations of dispatcher
data/Gemfile CHANGED
@@ -1,3 +1,2 @@
1
1
  source 'https://rubygems.org'
2
2
  gemspec
3
- gem 'codeclimate-test-reporter', group: :test, require: nil
data/Makefile CHANGED
@@ -12,6 +12,10 @@ mutate: test ## Run mutation tests
12
12
  @echo "Running mutation tests - only 100% free mutation will be accepted"
13
13
  @bundle exec mutant --include lib --require ruby_event_store --use rspec --ignore-subject "RubyEventStore.const_missing" "RubyEventStore*"
14
14
 
15
+ release:
16
+ @rake build
17
+ @rake release:rubygem_push
18
+
15
19
  .PHONY: help
16
20
 
17
21
  help:
data/README.md CHANGED
@@ -1,50 +1,3 @@
1
- [![Build Status](https://travis-ci.org/arkency/ruby_event_store.svg?branch=master)](https://travis-ci.org/arkency/ruby_event_store)
2
- [![Gem Version](https://badge.fury.io/rb/ruby_event_store.svg)](http://badge.fury.io/rb/ruby_event_store)
3
- [![Code Climate](https://codeclimate.com/github/arkency/ruby_event_store/badges/gpa.svg)](https://codeclimate.com/github/arkency/ruby_event_store)
4
- [![Test Coverage](https://codeclimate.com/github/arkency/ruby_event_store/badges/coverage.svg)](https://codeclimate.com/github/arkency/ruby_event_store/coverage)
5
- [![Join the chat at https://gitter.im/arkency/rails_event_store](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/arkency/rails_event_store?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
6
-
7
1
  # RubyEventStore
8
2
 
9
- A Ruby implementation of an EventStore. It is an integral part of [rails_event_store](http://github.com/arkency/rails_event_store) gem.
10
-
11
- # Documentation
12
-
13
- All documentation and sample codes are available at [http://railseventstore.arkency.com](http://railseventstore.arkency.com)
14
-
15
- # Contributing
16
-
17
- Check the contribution guide on [CONTRIBUTING.md](https://github.com/arkency/ruby_event_store/blob/master/CONTRIBUTING.md)
18
-
19
- We're aiming for 100% mutation coverage in this project.
20
- Read the reasoning:
21
-
22
- [Why I want to introduce mutation testing to the rails_event_store gem](http://blog.arkency.com/2015/04/why-i-want-to-introduce-mutation-testing-to-the-rails-event-store-gem/)
23
-
24
- [Mutation testing and continuous integration](http://blog.arkency.com/2015/05/mutation-testing-and-continuous-integration/)
25
-
26
- In practice, it means that we run `make mutate` as part of the CI process.
27
- Whenever you fix a bug or add a new feature, we require that the coverage doesn't go down.
28
-
29
- ## About
30
-
31
- <img src="http://arkency.com/images/arkency.png" alt="Arkency" width="60px" align="left" />
32
-
33
- This repository is funded and maintained by Arkency. Check out our other [open-source projects](https://github.com/arkency).
34
-
35
- You can also [hire us](http://arkency.com) or [read our blog](http://blog.arkency.com).
36
-
37
-
38
- ## Learn more about DDD & Event Sourcing
39
-
40
- Check our **Rails + Domain Driven Design Workshop** [more details](http://blog.arkency.com/ddd-training/).
41
-
42
- Why You should attend? Robert has explained this in [this blogpost](http://blog.arkency.com/2016/12/why-would-you-even-want-to-listen-about-ddd/).
43
-
44
-
45
- Next edition will be held on **21-22th September 2017** in Berlin, Germany.
46
- Another edition is also planned for November in London.
47
-
48
- You may also consider buying the [Domain-Driven Rails book](http://blog.arkency.com/domain-driven-rails/).
49
- Workshop will be held in English.
50
-
3
+ A Ruby implementation of an EventStore. It is an integral part of `rails_event_store` gem.
@@ -32,6 +32,7 @@ module RubyEventStore
32
32
 
33
33
  def verify_subscriber(subscriber)
34
34
  raise SubscriberNotExist if subscriber.nil?
35
+ raise InvalidHandler.new(subscriber) unless subscriber.respond_to?(:call)
35
36
  end
36
37
 
37
38
  def subscribe(subscriber, event_types)
@@ -2,7 +2,6 @@ module RubyEventStore
2
2
  module PubSub
3
3
  class Dispatcher
4
4
  def call(subscriber, event)
5
- raise InvalidHandler.new(subscriber) unless subscriber.respond_to?(:call)
6
5
  subscriber.call(event)
7
6
  end
8
7
  end
@@ -6,12 +6,4 @@ RSpec.shared_examples :dispatcher do |dispatcher|
6
6
  expect(handler).to receive(:call).with(event)
7
7
  dispatcher.(handler, event)
8
8
  end
9
-
10
- specify "error when invalid subscriber passed" do
11
- handler = double(:handler)
12
- event = instance_double(::RubyEventStore::Event)
13
-
14
- expect { dispatcher.(handler, event) }.to raise_error(::RubyEventStore::InvalidHandler,
15
- "#call method not found in RSpec::Mocks::Double subscriber. Are you sure it is a valid subscriber?")
16
- end
17
9
  end
@@ -62,8 +62,7 @@ RSpec.shared_examples :event_broker do |broker_class|
62
62
  "in InvalidTestHandler subscriber." +
63
63
  " Are you sure it is a valid subscriber?"
64
64
  subscriber = InvalidTestHandler.new
65
- broker.add_subscriber(subscriber, [Test1DomainEvent])
66
- expect { broker.notify_subscribers(Test1DomainEvent.new) }.to raise_error(RubyEventStore::InvalidHandler, message)
65
+ expect { broker.add_subscriber(subscriber, [Test1DomainEvent]) }.to raise_error(RubyEventStore::InvalidHandler, message)
67
66
  end
68
67
 
69
68
  it 'raises error when no valid method on global handler' do
@@ -71,8 +70,7 @@ RSpec.shared_examples :event_broker do |broker_class|
71
70
  "in InvalidTestHandler subscriber." +
72
71
  " Are you sure it is a valid subscriber?"
73
72
  subscriber = InvalidTestHandler.new
74
- broker.add_global_subscriber(subscriber)
75
- expect { broker.notify_subscribers(Test1DomainEvent.new) }.to raise_error(RubyEventStore::InvalidHandler, message)
73
+ expect { broker.add_global_subscriber(subscriber) }.to raise_error(RubyEventStore::InvalidHandler, message)
76
74
  end
77
75
 
78
76
  it 'returns lambda as an output of global subscribe methods' do
@@ -1,3 +1,3 @@
1
1
  module RubyEventStore
2
- VERSION = '0.14.0'
2
+ VERSION = "0.15.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruby_event_store
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.14.0
4
+ version: 0.15.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Arkency
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-08-21 00:00:00.000000000 Z
11
+ date: 2017-08-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -87,12 +87,8 @@ executables: []
87
87
  extensions: []
88
88
  extra_rdoc_files: []
89
89
  files:
90
- - ".gitignore"
91
- - ".travis.yml"
92
90
  - CHANGELOG.md
93
- - CONTRIBUTING.md
94
91
  - Gemfile
95
- - LICENSE
96
92
  - Makefile
97
93
  - README.md
98
94
  - Rakefile
data/.gitignore DELETED
@@ -1,9 +0,0 @@
1
- /.bundle/
2
- /.yardoc
3
- /Gemfile.lock
4
- /_yardoc/
5
- /coverage/
6
- /doc/
7
- /pkg/
8
- /spec/reports/
9
- /tmp/
@@ -1,13 +0,0 @@
1
- language: ruby
2
- rvm:
3
- - 2.2.7
4
- - 2.3.4
5
- - 2.4.1
6
- before_install: gem install bundler
7
- gemfile: Gemfile
8
- script: make mutate
9
- notifications:
10
- slack:
11
- secure: qCcGv1MmryEhPoHzTvZvgSv21UcC7j2Cfq0b0hmQWuYHrHN+jhqjhg7PuElNyr0mk6N1acIcVqOAWpS20ZkG/mipW2RBBXVEc9zVR10pvJnlKDmGKd4Vmj394VgIknn8ciruglw1LoJManf1bV7/Wm4ITMt3zCQqTMGclRUqA0l/dzK2z9zU35cT4v38nTGnoGVrPQx29FvpU3J/h9qC6kGllw3Bkic2nmpFABYOI49LQFF3/vdrbnK3Zo1rudHMV0lNoPg5Ntrbd6XHXUKrBGBcZmGSh3wW/mfYf9Tcft+5MwtCu4b70KnFknx7oFmBlU8JFYg2x5f1xNSIoRkDmLI5/jNDWJ3oLAtYjgY5CdBMlxnhhfnCBmbaxEJhTuscm2sIp+S+4+ggm8x/daIK3BUaBAV5BT8An52BXhQ/F6cdnYiSVn+5lGap/1wF2TWwnN/oVc+JVfATouG9FCygzMekUaji94JMKBtS+QgoLdAE5ufEGBeDONJELRD8Lca1R4uWSg2snf93GWoONca9aJfkIfXj3m+VaoAM9Bq9DGcOXwZESkltE2E+31Fznh5qYCRH1zgtgB0Hx8x7sdaxNQyybvgNS1R0lGnIU/NrUmREcUi5BYEI5YqygBtkTZ7F/nlYQgydKjjHJ6FG3oLc3ggxffE8oAdpuxvlUQ8ZN6o=
12
- env:
13
- - CODECLIMATE_REPO_TOKEN=164ccfacd5c379b0113f81b055179574f55d8611bac432b3e9bd5f7c5858084a
@@ -1,27 +0,0 @@
1
- # Contributing to RubyEventStore
2
-
3
- Any kind of contribution is welcomed. Here is a few guidelines that we need contributors to follow.
4
-
5
- ## Found a bug? Have a question?
6
-
7
- * [Create a new issue](https://github.com/arkency/ruby_event_store/issues/new), assuming one does not already exist.
8
- * Clearly describe the issue including steps to reproduce when it is a bug.
9
- * If possible provide a Pull Request with failing test case.
10
-
11
- ## Getting Started
12
-
13
- * Make sure you have a [GitHub account](https://github.com/signup/free).
14
- * [Fork the repository](https://help.github.com/articles/fork-a-repo/) on GitHub.
15
-
16
- ## Making Changes
17
-
18
- * Create a feature branch from where you want to base your work.
19
- * Do your work. Please try to keep your commits small and focussed.
20
- * Make sure you have added the necessary tests for your changes.
21
- * Push your changes to a feature branch in your fork of the repository.
22
- * Submit a pull request to the RubyEventStore repository.
23
-
24
- # Additional Resources
25
-
26
- * [General GitHub documentation](http://help.github.com/)
27
- * [GitHub pull request documentation](http://help.github.com/send-pull-requests/)
data/LICENSE DELETED
@@ -1,22 +0,0 @@
1
- The MIT License (MIT)
2
-
3
- Copyright (c) 2015 Arkency
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
- SOFTWARE.
22
-