axiom-memory-adapter 0.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +37 -0
- data/.rspec +4 -0
- data/.ruby-gemset +1 -0
- data/.travis.yml +28 -0
- data/.yardopts +4 -0
- data/CONTRIBUTING.md +11 -0
- data/Gemfile +8 -0
- data/Gemfile.devtools +60 -0
- data/Guardfile +24 -0
- data/LICENSE +20 -0
- data/README.md +49 -0
- data/Rakefile +5 -0
- data/TODO +1 -0
- data/axiom-memory-adapter.gemspec +23 -0
- data/config/devtools.yml +2 -0
- data/config/flay.yml +3 -0
- data/config/flog.yml +2 -0
- data/config/mutant.yml +3 -0
- data/config/reek.yml +107 -0
- data/config/yardstick.yml +2 -0
- data/lib/axiom-memory-adapter.rb +3 -0
- data/lib/axiom/adapter/memory.rb +98 -0
- data/lib/axiom/adapter/memory/version.rb +12 -0
- data/spec/spec_helper.rb +32 -0
- metadata +106 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 94c19af0600da7b06aefddead4f489e717f8ea41
|
4
|
+
data.tar.gz: 33cd3eb27a5a3bbafc7e7b534b64f333633b7565
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 503db171d87002481874517f3eedb4dfce7d3bdb2358873e2e7fb9c3befb44a9468abceef5b4cab96f1c1647b9273eb5b0dae9a228075dc6a685c55dd4b37986
|
7
|
+
data.tar.gz: cacf03827d491e6940e84958e83b5d1d6a9f38849357b0c07cb49649d2d787777546454d58cc879a4676eef33825ff8193181f3aaba7d1c7585baff41a2f7ee3
|
data/.gitignore
ADDED
@@ -0,0 +1,37 @@
|
|
1
|
+
## MAC OS
|
2
|
+
.DS_Store
|
3
|
+
|
4
|
+
## TEXTMATE
|
5
|
+
*.tmproj
|
6
|
+
tmtags
|
7
|
+
|
8
|
+
## EMACS
|
9
|
+
*~
|
10
|
+
\#*
|
11
|
+
.\#*
|
12
|
+
|
13
|
+
## VIM
|
14
|
+
*.sw[op]
|
15
|
+
|
16
|
+
## Rubinius
|
17
|
+
*.rbc
|
18
|
+
.rbx
|
19
|
+
|
20
|
+
## PROJECT::GENERAL
|
21
|
+
*.gem
|
22
|
+
coverage
|
23
|
+
profiling
|
24
|
+
turbulence
|
25
|
+
rdoc
|
26
|
+
pkg
|
27
|
+
tmp
|
28
|
+
doc
|
29
|
+
log
|
30
|
+
.yardoc
|
31
|
+
measurements
|
32
|
+
|
33
|
+
## BUNDLER
|
34
|
+
.bundle
|
35
|
+
Gemfile.lock
|
36
|
+
|
37
|
+
## PROJECT::SPECIFIC
|
data/.rspec
ADDED
data/.ruby-gemset
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
axiom-memory-adapter
|
data/.travis.yml
ADDED
@@ -0,0 +1,28 @@
|
|
1
|
+
language: ruby
|
2
|
+
before_install: gem install bundler
|
3
|
+
bundler_args: --without yard guard benchmarks
|
4
|
+
script: "bundle exec rake ci"
|
5
|
+
rvm:
|
6
|
+
- 1.9.3
|
7
|
+
- 2.0.0
|
8
|
+
- ruby-head
|
9
|
+
- rbx-19mode
|
10
|
+
- jruby-19mode
|
11
|
+
- jruby-head
|
12
|
+
notifications:
|
13
|
+
irc:
|
14
|
+
channels:
|
15
|
+
- irc.freenode.org#rom-rb
|
16
|
+
on_success: never
|
17
|
+
on_failure: change
|
18
|
+
email:
|
19
|
+
recipients:
|
20
|
+
- dan.kubb@gmail.com
|
21
|
+
on_success: never
|
22
|
+
on_failure: change
|
23
|
+
matrix:
|
24
|
+
include:
|
25
|
+
- rvm: jruby-19mode
|
26
|
+
env: JRUBY_OPTS="$JRUBY_OPTS --debug"
|
27
|
+
- rvm: jruby-head
|
28
|
+
env: JRUBY_OPTS="$JRUBY_OPTS --debug"
|
data/.yardopts
ADDED
data/CONTRIBUTING.md
ADDED
@@ -0,0 +1,11 @@
|
|
1
|
+
Contributing
|
2
|
+
------------
|
3
|
+
|
4
|
+
* If you want your code merged into the mainline, please discuss the proposed changes with me before doing any work on it. This library is still in early development, and the direction it is going may not always be clear. Some features may not be appropriate yet, may need to be deferred until later when the foundation for them is laid, or may be more applicable in a plugin.
|
5
|
+
* Fork the project.
|
6
|
+
* Make your feature addition or bug fix.
|
7
|
+
* Follow this [style guide](https://github.com/dkubb/styleguide).
|
8
|
+
* Add specs for it. This is important so I don't break it in a future version unintentionally. Tests must cover all branches within the code, and code must be fully covered.
|
9
|
+
* Commit, do not mess with Rakefile, version, or history. (if you want to have your own version, that is fine but bump version in a commit by itself I can ignore when I pull)
|
10
|
+
* Run "rake ci". This must pass and not show any regressions in the metrics for the code to be merged.
|
11
|
+
* Send me a pull request. Bonus points for topic branches.
|
data/Gemfile
ADDED
data/Gemfile.devtools
ADDED
@@ -0,0 +1,60 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
|
3
|
+
group :development do
|
4
|
+
gem 'rake', '~> 10.0.4'
|
5
|
+
gem 'rspec', '~> 2.13.0'
|
6
|
+
gem 'yard', '~> 0.8.6.1'
|
7
|
+
end
|
8
|
+
|
9
|
+
group :yard do
|
10
|
+
gem 'kramdown', '~> 1.0.1'
|
11
|
+
end
|
12
|
+
|
13
|
+
group :guard do
|
14
|
+
gem 'guard', '~> 1.8.0'
|
15
|
+
gem 'guard-bundler', '~> 1.0.0'
|
16
|
+
gem 'guard-rspec', '~> 3.0.2'
|
17
|
+
|
18
|
+
# file system change event handling
|
19
|
+
gem 'listen', '~> 1.2.1'
|
20
|
+
gem 'rb-fchange', '~> 0.0.6', :require => false
|
21
|
+
gem 'rb-fsevent', '~> 0.9.3', :require => false
|
22
|
+
gem 'rb-inotify', '~> 0.9.0', :require => false
|
23
|
+
|
24
|
+
# notification handling
|
25
|
+
gem 'libnotify', '~> 0.8.0', :require => false
|
26
|
+
gem 'rb-notifu', '~> 0.0.4', :require => false
|
27
|
+
gem 'terminal-notifier-guard', '~> 1.5.3', :require => false
|
28
|
+
end
|
29
|
+
|
30
|
+
group :metrics do
|
31
|
+
gem 'backports', '~> 3.3', '>= 3.3.2'
|
32
|
+
gem 'coveralls', '~> 0.6.7'
|
33
|
+
gem 'flay', '~> 2.3.0'
|
34
|
+
gem 'flog', '~> 4.1.0'
|
35
|
+
gem 'reek', '~> 1.3.1', :git => 'https://github.com/troessner/reek.git'
|
36
|
+
gem 'simplecov', '~> 0.7.1'
|
37
|
+
gem 'yardstick', '~> 0.9.6'
|
38
|
+
|
39
|
+
platforms :ruby_19 do
|
40
|
+
gem 'yard-spellcheck', '~> 0.1.5'
|
41
|
+
end
|
42
|
+
|
43
|
+
platforms :mri_19, :rbx do
|
44
|
+
gem 'mutant', '~> 0.2.20'
|
45
|
+
end
|
46
|
+
|
47
|
+
platforms :rbx do
|
48
|
+
gem 'pelusa', '~> 0.2.2'
|
49
|
+
end
|
50
|
+
end
|
51
|
+
|
52
|
+
group :benchmarks do
|
53
|
+
gem 'rbench', '~> 0.2.3'
|
54
|
+
end
|
55
|
+
|
56
|
+
platform :jruby do
|
57
|
+
group :jruby do
|
58
|
+
gem 'jruby-openssl', '~> 0.8.5'
|
59
|
+
end
|
60
|
+
end
|
data/Guardfile
ADDED
@@ -0,0 +1,24 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
|
3
|
+
guard :bundler do
|
4
|
+
watch('Gemfile')
|
5
|
+
watch('axiom-memory-adapter.gemspec')
|
6
|
+
end
|
7
|
+
|
8
|
+
guard :rspec, :keep_failed => false do
|
9
|
+
# run all specs if configuration is modified
|
10
|
+
watch('Guardfile') { 'spec' }
|
11
|
+
watch('Gemfile.lock') { 'spec' }
|
12
|
+
watch('spec/spec_helper.rb') { 'spec' }
|
13
|
+
|
14
|
+
# run all specs if supporting files files are modified
|
15
|
+
watch(%r{\Aspec/(?:lib|support|shared)/.+\.rb\z}) { 'spec' }
|
16
|
+
|
17
|
+
# run unit specs if associated lib code is modified
|
18
|
+
watch(%r{\Alib/(.+)\.rb\z}) { |m| Dir["spec/unit/#{m[1]}"] }
|
19
|
+
watch(%r{\Alib/(.+)/support/(.+)\.rb\z}) { |m| Dir["spec/unit/#{m[1]}/#{m[2]}"] }
|
20
|
+
watch("lib/#{File.basename(File.expand_path('../', __FILE__))}.rb") { 'spec' }
|
21
|
+
|
22
|
+
# run a spec if it is modified
|
23
|
+
watch(%r{\Aspec/(?:unit|integration)/.+_spec\.rb\z})
|
24
|
+
end
|
data/LICENSE
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
Copyright (c) 2013 Dan Kubb
|
2
|
+
|
3
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
4
|
+
a copy of this software and associated documentation files (the
|
5
|
+
"Software"), to deal in the Software without restriction, including
|
6
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
7
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
8
|
+
permit persons to whom the Software is furnished to do so, subject to
|
9
|
+
the following conditions:
|
10
|
+
|
11
|
+
The above copyright notice and this permission notice shall be
|
12
|
+
included in all copies or substantial portions of the Software.
|
13
|
+
|
14
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
15
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
16
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
17
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
18
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
19
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
20
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,49 @@
|
|
1
|
+
[![Gem Version](https://badge.fury.io/rb/axiom-memory-adapter.png)][gem]
|
2
|
+
[![Build Status](https://secure.travis-ci.org/dkubb/axiom-memory-adapter.png?branch=master)][travis]
|
3
|
+
[![Dependency Status](https://gemnasium.com/dkubb/axiom-memory-adapter.png)][gemnasium]
|
4
|
+
[![Code Climate](https://codeclimate.com/github/dkubb/axiom-memory-adapter.png)][codeclimate]
|
5
|
+
[![Coverage Status](https://coveralls.io/repos/dkubb/axiom-memory-adapter/badge.png?branch=master)][coveralls]
|
6
|
+
|
7
|
+
[gem]: https://rubygems.org/gems/axiom-memory-adapter
|
8
|
+
[travis]: https://travis-ci.org/dkubb/axiom-memory-adapter
|
9
|
+
[gemnasium]: https://gemnasium.com/dkubb/axiom-memory-adapter
|
10
|
+
[codeclimate]: https://codeclimate.com/github/dkubb/axiom-memory-adapter
|
11
|
+
[coveralls]: https://coveralls.io/r/dkubb/axiom-memory-adapter
|
12
|
+
|
13
|
+
axiom-memory-adapter
|
14
|
+
====================
|
15
|
+
|
16
|
+
Use Axiom relations with an in-memory datastore
|
17
|
+
|
18
|
+
Installation
|
19
|
+
------------
|
20
|
+
|
21
|
+
With Rubygems:
|
22
|
+
|
23
|
+
```bash
|
24
|
+
$ gem install axiom-memory-adapter
|
25
|
+
$ irb -rubygems
|
26
|
+
>> require 'axiom-memory-adapter'
|
27
|
+
=> true
|
28
|
+
```
|
29
|
+
|
30
|
+
With git and local working copy:
|
31
|
+
|
32
|
+
```bash
|
33
|
+
$ git clone git://github.com/dkubb/axiom-memory-adapter.git
|
34
|
+
$ cd axiom-memory-adapter
|
35
|
+
$ rake install
|
36
|
+
$ irb -rubygems
|
37
|
+
>> require 'axiom-memory-adapter'
|
38
|
+
=> true
|
39
|
+
```
|
40
|
+
|
41
|
+
Contributing
|
42
|
+
-------------
|
43
|
+
|
44
|
+
See [CONTRIBUTING.md](CONTRIBUTING.md) for details.
|
45
|
+
|
46
|
+
Copyright
|
47
|
+
---------
|
48
|
+
|
49
|
+
Copyright © 2013 Dan Kubb. See LICENSE for details.
|
data/Rakefile
ADDED
@@ -0,0 +1,23 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
|
3
|
+
require File.expand_path('../lib/axiom/adapter/memory/version', __FILE__)
|
4
|
+
|
5
|
+
Gem::Specification.new do |gem|
|
6
|
+
gem.name = 'axiom-memory-adapter'
|
7
|
+
gem.version = Axiom::Adapter::Memory::VERSION.dup
|
8
|
+
gem.authors = ['Dan Kubb']
|
9
|
+
gem.email = 'dan.kubb@gmail.com'
|
10
|
+
gem.description = 'Use Axiom relations with an in-memory datastore'
|
11
|
+
gem.summary = 'Axiom Memory adapter'
|
12
|
+
gem.homepage = 'https://github.com/dkubb/axiom-memory-adapter'
|
13
|
+
gem.licenses = %w[MIT]
|
14
|
+
|
15
|
+
gem.require_paths = %w[lib]
|
16
|
+
gem.files = `git ls-files`.split($/)
|
17
|
+
gem.test_files = `git ls-files -- spec/{unit,integration}`.split($/)
|
18
|
+
gem.extra_rdoc_files = %w[LICENSE README.md CONTRIBUTING.md TODO]
|
19
|
+
|
20
|
+
gem.add_runtime_dependency('axiom', '~> 0.1.0')
|
21
|
+
|
22
|
+
gem.add_development_dependency('bundler', '~> 1.3', '>= 1.3.5')
|
23
|
+
end
|
data/config/devtools.yml
ADDED
data/config/flay.yml
ADDED
data/config/flog.yml
ADDED
data/config/mutant.yml
ADDED
data/config/reek.yml
ADDED
@@ -0,0 +1,107 @@
|
|
1
|
+
---
|
2
|
+
Attribute:
|
3
|
+
enabled: true
|
4
|
+
exclude: []
|
5
|
+
BooleanParameter:
|
6
|
+
enabled: true
|
7
|
+
exclude: []
|
8
|
+
ClassVariable:
|
9
|
+
enabled: true
|
10
|
+
exclude: []
|
11
|
+
ControlParameter:
|
12
|
+
enabled: true
|
13
|
+
exclude: []
|
14
|
+
DataClump:
|
15
|
+
enabled: true
|
16
|
+
exclude: []
|
17
|
+
max_copies: 2
|
18
|
+
min_clump_size: 2
|
19
|
+
DuplicateMethodCall:
|
20
|
+
enabled: true
|
21
|
+
exclude: []
|
22
|
+
max_calls: 1
|
23
|
+
allow_calls: []
|
24
|
+
FeatureEnvy:
|
25
|
+
enabled: true
|
26
|
+
exclude: []
|
27
|
+
IrresponsibleModule:
|
28
|
+
enabled: true
|
29
|
+
exclude: []
|
30
|
+
LongParameterList:
|
31
|
+
enabled: true
|
32
|
+
exclude: []
|
33
|
+
max_params: 2
|
34
|
+
overrides:
|
35
|
+
initialize:
|
36
|
+
max_params: 3
|
37
|
+
LongYieldList:
|
38
|
+
enabled: true
|
39
|
+
exclude: []
|
40
|
+
max_params: 2
|
41
|
+
NestedIterators:
|
42
|
+
enabled: true
|
43
|
+
exclude: []
|
44
|
+
max_allowed_nesting: 1
|
45
|
+
ignore_iterators: []
|
46
|
+
NilCheck:
|
47
|
+
enabled: true
|
48
|
+
exclude: []
|
49
|
+
RepeatedConditional:
|
50
|
+
enabled: true
|
51
|
+
exclude: []
|
52
|
+
max_ifs: 1
|
53
|
+
TooManyInstanceVariables:
|
54
|
+
enabled: true
|
55
|
+
exclude: []
|
56
|
+
max_instance_variables: 3
|
57
|
+
TooManyMethods:
|
58
|
+
enabled: true
|
59
|
+
exclude: []
|
60
|
+
max_methods: 10
|
61
|
+
TooManyStatements:
|
62
|
+
enabled: true
|
63
|
+
exclude:
|
64
|
+
- each
|
65
|
+
max_statements: 2
|
66
|
+
UncommunicativeMethodName:
|
67
|
+
enabled: true
|
68
|
+
exclude: []
|
69
|
+
reject:
|
70
|
+
- !ruby/regexp /^[a-z]$/
|
71
|
+
- !ruby/regexp /[0-9]$/
|
72
|
+
- !ruby/regexp /[A-Z]/
|
73
|
+
accept: []
|
74
|
+
UncommunicativeModuleName:
|
75
|
+
enabled: true
|
76
|
+
exclude: []
|
77
|
+
reject:
|
78
|
+
- !ruby/regexp /^.$/
|
79
|
+
- !ruby/regexp /[0-9]$/
|
80
|
+
accept: []
|
81
|
+
UncommunicativeParameterName:
|
82
|
+
enabled: true
|
83
|
+
exclude: []
|
84
|
+
reject:
|
85
|
+
- !ruby/regexp /^.$/
|
86
|
+
- !ruby/regexp /[0-9]$/
|
87
|
+
- !ruby/regexp /[A-Z]/
|
88
|
+
accept: []
|
89
|
+
UncommunicativeVariableName:
|
90
|
+
enabled: true
|
91
|
+
exclude: []
|
92
|
+
reject:
|
93
|
+
- !ruby/regexp /^.$/
|
94
|
+
- !ruby/regexp /[0-9]$/
|
95
|
+
- !ruby/regexp /[A-Z]/
|
96
|
+
accept: []
|
97
|
+
UnusedParameters:
|
98
|
+
enabled: true
|
99
|
+
exclude:
|
100
|
+
- Axiom::Adapter::Memory#delete
|
101
|
+
- Axiom::Adapter::Memory#insert
|
102
|
+
- Axiom::Adapter::Memory#read
|
103
|
+
- Axiom::Adapter::Memory#update
|
104
|
+
UtilityFunction:
|
105
|
+
enabled: true
|
106
|
+
exclude: []
|
107
|
+
max_helper_calls: 0
|
@@ -0,0 +1,98 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
|
3
|
+
require 'axiom'
|
4
|
+
|
5
|
+
module Axiom
|
6
|
+
module Adapter
|
7
|
+
|
8
|
+
# A reference adapter for in-memory information
|
9
|
+
class Memory
|
10
|
+
include Adamantium
|
11
|
+
|
12
|
+
# Initialize a Memory adapter
|
13
|
+
#
|
14
|
+
# @return [undefined]
|
15
|
+
#
|
16
|
+
# @api private
|
17
|
+
def initialize
|
18
|
+
# TODO: add a registry to map base relation names to tuples
|
19
|
+
end
|
20
|
+
|
21
|
+
# Insert a set of tuples into memory
|
22
|
+
#
|
23
|
+
# @example insert a new user
|
24
|
+
# header = Axiom::Header.coerce([ [ :name, String ] ])
|
25
|
+
# tuple = Axiom::Tuple.new(header, [ 'Dan Kubb' ])
|
26
|
+
# adapter.insert(users, [ tuple ])
|
27
|
+
#
|
28
|
+
# @param [Axiom::Relation] relation
|
29
|
+
# @param [Enumerable<Axiom::Tuple>] tuples
|
30
|
+
# a set of tuples to insert into the relation
|
31
|
+
#
|
32
|
+
# @return [self]
|
33
|
+
#
|
34
|
+
# @api public
|
35
|
+
def insert(relation, tuples)
|
36
|
+
raise NotImplementedError, "#{self.class}##{__method__} not implemented"
|
37
|
+
end
|
38
|
+
|
39
|
+
# Read the results from memory
|
40
|
+
#
|
41
|
+
# @example
|
42
|
+
# adapter.read(users) { |row| ... }
|
43
|
+
#
|
44
|
+
# @param [Axiom::Relation] relation
|
45
|
+
#
|
46
|
+
# @yield [row]
|
47
|
+
#
|
48
|
+
# @yieldparam [Array] row
|
49
|
+
# each row in the results
|
50
|
+
#
|
51
|
+
# @return [self]
|
52
|
+
#
|
53
|
+
# @api public
|
54
|
+
def read(relation)
|
55
|
+
raise NotImplementedError, "#{self.class}##{__method__} not implemented"
|
56
|
+
end
|
57
|
+
|
58
|
+
# Update the tuples in memory that intersect the relation
|
59
|
+
#
|
60
|
+
# @example update all users to be active
|
61
|
+
# header = Axiom::Header.coerce([ [ :active, TrueClass ] ])
|
62
|
+
# tuple = Axiom::Tuple.new(header, [ true ])
|
63
|
+
# adapter.update(inactive_users, tuple)
|
64
|
+
#
|
65
|
+
# The tuple header must be a subset of the base relation header. Every
|
66
|
+
# tuple in the relation should have the overlapping attributes changed
|
67
|
+
# to match the tuple. The tuple header must not be a superset of any
|
68
|
+
# keys and cause a uniqueness constraint violation.
|
69
|
+
#
|
70
|
+
# @param [Axiom::Relation] relation
|
71
|
+
# @param [Axiom::Tuple] tuple
|
72
|
+
#
|
73
|
+
# @return [self]
|
74
|
+
#
|
75
|
+
# @api public
|
76
|
+
def update(relation, tuple)
|
77
|
+
raise NotImplementedError, "#{self.class}##{__method}} not implemented"
|
78
|
+
end
|
79
|
+
|
80
|
+
# Delete tuples from memory that intersect with the relation
|
81
|
+
#
|
82
|
+
# @example
|
83
|
+
# adapter.delete(inactive_users)
|
84
|
+
#
|
85
|
+
# @param [Axiom::Relation] relation
|
86
|
+
#
|
87
|
+
# @return [self]
|
88
|
+
#
|
89
|
+
# @api public
|
90
|
+
def delete(relation)
|
91
|
+
raise NotImplementedError, "#{self.class}##{__method}} not implemented"
|
92
|
+
end
|
93
|
+
|
94
|
+
end # class Memory
|
95
|
+
end # module Adapter
|
96
|
+
end # module Axiom
|
97
|
+
|
98
|
+
require 'axiom/adapter/memory/version'
|
data/spec/spec_helper.rb
ADDED
@@ -0,0 +1,32 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
|
3
|
+
if ENV['COVERAGE'] == 'true'
|
4
|
+
require 'simplecov'
|
5
|
+
require 'coveralls'
|
6
|
+
|
7
|
+
SimpleCov.formatter = SimpleCov::Formatter::MultiFormatter[
|
8
|
+
SimpleCov::Formatter::HTMLFormatter,
|
9
|
+
Coveralls::SimpleCov::Formatter
|
10
|
+
]
|
11
|
+
|
12
|
+
SimpleCov.start do
|
13
|
+
command_name 'spec:unit'
|
14
|
+
add_filter 'config/'
|
15
|
+
add_filter 'spec/'
|
16
|
+
minimum_coverage 100
|
17
|
+
end
|
18
|
+
end
|
19
|
+
|
20
|
+
require 'axiom-memory-adapter'
|
21
|
+
require 'devtools/spec_helper'
|
22
|
+
|
23
|
+
# require spec support files and shared behavior
|
24
|
+
Dir[File.expand_path('../{support,shared}/**/*.rb', __FILE__)].each do |file|
|
25
|
+
require file
|
26
|
+
end
|
27
|
+
|
28
|
+
RSpec.configure do |config|
|
29
|
+
config.expect_with :rspec do |expect_with|
|
30
|
+
expect_with.syntax = :expect
|
31
|
+
end
|
32
|
+
end
|
metadata
ADDED
@@ -0,0 +1,106 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: axiom-memory-adapter
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.0.1
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Dan Kubb
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2013-06-20 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: axiom
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - ~>
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: 0.1.0
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - ~>
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: 0.1.0
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: bundler
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - ~>
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '1.3'
|
34
|
+
- - '>='
|
35
|
+
- !ruby/object:Gem::Version
|
36
|
+
version: 1.3.5
|
37
|
+
type: :development
|
38
|
+
prerelease: false
|
39
|
+
version_requirements: !ruby/object:Gem::Requirement
|
40
|
+
requirements:
|
41
|
+
- - ~>
|
42
|
+
- !ruby/object:Gem::Version
|
43
|
+
version: '1.3'
|
44
|
+
- - '>='
|
45
|
+
- !ruby/object:Gem::Version
|
46
|
+
version: 1.3.5
|
47
|
+
description: Use Axiom relations with an in-memory datastore
|
48
|
+
email: dan.kubb@gmail.com
|
49
|
+
executables: []
|
50
|
+
extensions: []
|
51
|
+
extra_rdoc_files:
|
52
|
+
- LICENSE
|
53
|
+
- README.md
|
54
|
+
- CONTRIBUTING.md
|
55
|
+
- TODO
|
56
|
+
files:
|
57
|
+
- .gitignore
|
58
|
+
- .rspec
|
59
|
+
- .ruby-gemset
|
60
|
+
- .travis.yml
|
61
|
+
- .yardopts
|
62
|
+
- CONTRIBUTING.md
|
63
|
+
- Gemfile
|
64
|
+
- Gemfile.devtools
|
65
|
+
- Guardfile
|
66
|
+
- LICENSE
|
67
|
+
- README.md
|
68
|
+
- Rakefile
|
69
|
+
- TODO
|
70
|
+
- axiom-memory-adapter.gemspec
|
71
|
+
- config/devtools.yml
|
72
|
+
- config/flay.yml
|
73
|
+
- config/flog.yml
|
74
|
+
- config/mutant.yml
|
75
|
+
- config/reek.yml
|
76
|
+
- config/yardstick.yml
|
77
|
+
- lib/axiom-memory-adapter.rb
|
78
|
+
- lib/axiom/adapter/memory.rb
|
79
|
+
- lib/axiom/adapter/memory/version.rb
|
80
|
+
- spec/spec_helper.rb
|
81
|
+
homepage: https://github.com/dkubb/axiom-memory-adapter
|
82
|
+
licenses:
|
83
|
+
- MIT
|
84
|
+
metadata: {}
|
85
|
+
post_install_message:
|
86
|
+
rdoc_options: []
|
87
|
+
require_paths:
|
88
|
+
- lib
|
89
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
90
|
+
requirements:
|
91
|
+
- - '>='
|
92
|
+
- !ruby/object:Gem::Version
|
93
|
+
version: '0'
|
94
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
95
|
+
requirements:
|
96
|
+
- - '>='
|
97
|
+
- !ruby/object:Gem::Version
|
98
|
+
version: '0'
|
99
|
+
requirements: []
|
100
|
+
rubyforge_project:
|
101
|
+
rubygems_version: 2.0.3
|
102
|
+
signing_key:
|
103
|
+
specification_version: 4
|
104
|
+
summary: Axiom Memory adapter
|
105
|
+
test_files: []
|
106
|
+
has_rdoc:
|