quby-mongoid 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,6 @@
1
+ require 'spec_helper'
2
+ require 'quby/answer_repos/specs'
3
+
4
+ describe Quby::AnswerRepos::MongoidRepo do
5
+ it_behaves_like "an answer repository"
6
+ end
@@ -0,0 +1,31 @@
1
+ ENV["RAILS_ENV"] = "test"
2
+ ENV["RACK_ENV"] = "test"
3
+ ENV["MONGOID_ENV"] = "test"
4
+
5
+ require 'quby/mongoid'
6
+ Quby.questionnaires_path = File.expand_path("../fixtures", __FILE__)
7
+
8
+ require 'mongoid'
9
+ if ::Mongoid::VERSION > '4'
10
+ Mongoid.load!(File.expand_path("../../config/mongoid4.yml", __FILE__), :test)
11
+ elsif ::Mongoid::VERSION > '3'
12
+ Mongoid.load!(File.expand_path("../../config/mongoid3.yml", __FILE__), :test)
13
+ else
14
+ Mongoid.load!(File.expand_path("../../config/mongoid2.yml", __FILE__))
15
+ end
16
+
17
+ require 'database_cleaner'
18
+ RSpec.configure do |config|
19
+ config.before(:suite) do
20
+ DatabaseCleaner[:mongoid].clean_with(:truncation)
21
+ DatabaseCleaner[:mongoid].strategy = :truncation
22
+ end
23
+
24
+ config.before(:each) do
25
+ DatabaseCleaner.start
26
+ end
27
+
28
+ config.after(:each) do
29
+ DatabaseCleaner.clean
30
+ end
31
+ end
metadata ADDED
@@ -0,0 +1,190 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: quby-mongoid
3
+ version: !ruby/object:Gem::Version
4
+ version: 1.0.0
5
+ platform: ruby
6
+ authors:
7
+ - Marten Veldthuis
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2014-06-25 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: quby
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: '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'
27
+ - !ruby/object:Gem::Dependency
28
+ name: mongoid
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: '2.2'
34
+ - - "<"
35
+ - !ruby/object:Gem::Version
36
+ version: '5.0'
37
+ type: :runtime
38
+ prerelease: false
39
+ version_requirements: !ruby/object:Gem::Requirement
40
+ requirements:
41
+ - - ">="
42
+ - !ruby/object:Gem::Version
43
+ version: '2.2'
44
+ - - "<"
45
+ - !ruby/object:Gem::Version
46
+ version: '5.0'
47
+ - !ruby/object:Gem::Dependency
48
+ name: bundler
49
+ requirement: !ruby/object:Gem::Requirement
50
+ requirements:
51
+ - - "~>"
52
+ - !ruby/object:Gem::Version
53
+ version: '1.6'
54
+ type: :development
55
+ prerelease: false
56
+ version_requirements: !ruby/object:Gem::Requirement
57
+ requirements:
58
+ - - "~>"
59
+ - !ruby/object:Gem::Version
60
+ version: '1.6'
61
+ - !ruby/object:Gem::Dependency
62
+ name: rake
63
+ requirement: !ruby/object:Gem::Requirement
64
+ requirements:
65
+ - - ">="
66
+ - !ruby/object:Gem::Version
67
+ version: '0'
68
+ type: :development
69
+ prerelease: false
70
+ version_requirements: !ruby/object:Gem::Requirement
71
+ requirements:
72
+ - - ">="
73
+ - !ruby/object:Gem::Version
74
+ version: '0'
75
+ - !ruby/object:Gem::Dependency
76
+ name: pry
77
+ requirement: !ruby/object:Gem::Requirement
78
+ requirements:
79
+ - - ">="
80
+ - !ruby/object:Gem::Version
81
+ version: '0'
82
+ type: :development
83
+ prerelease: false
84
+ version_requirements: !ruby/object:Gem::Requirement
85
+ requirements:
86
+ - - ">="
87
+ - !ruby/object:Gem::Version
88
+ version: '0'
89
+ - !ruby/object:Gem::Dependency
90
+ name: rspec
91
+ requirement: !ruby/object:Gem::Requirement
92
+ requirements:
93
+ - - "~>"
94
+ - !ruby/object:Gem::Version
95
+ version: 2.14.0
96
+ type: :development
97
+ prerelease: false
98
+ version_requirements: !ruby/object:Gem::Requirement
99
+ requirements:
100
+ - - "~>"
101
+ - !ruby/object:Gem::Version
102
+ version: 2.14.0
103
+ - !ruby/object:Gem::Dependency
104
+ name: database_cleaner
105
+ requirement: !ruby/object:Gem::Requirement
106
+ requirements:
107
+ - - ">="
108
+ - !ruby/object:Gem::Version
109
+ version: '0'
110
+ type: :development
111
+ prerelease: false
112
+ version_requirements: !ruby/object:Gem::Requirement
113
+ requirements:
114
+ - - ">="
115
+ - !ruby/object:Gem::Version
116
+ version: '0'
117
+ - !ruby/object:Gem::Dependency
118
+ name: rubocop
119
+ requirement: !ruby/object:Gem::Requirement
120
+ requirements:
121
+ - - "~>"
122
+ - !ruby/object:Gem::Version
123
+ version: 0.19.0
124
+ type: :development
125
+ prerelease: false
126
+ version_requirements: !ruby/object:Gem::Requirement
127
+ requirements:
128
+ - - "~>"
129
+ - !ruby/object:Gem::Version
130
+ version: 0.19.0
131
+ description: ''
132
+ email:
133
+ - marten@veldthuis.com
134
+ executables: []
135
+ extensions: []
136
+ extra_rdoc_files: []
137
+ files:
138
+ - ".gitignore"
139
+ - ".rubocop.yml"
140
+ - Appraisals
141
+ - Gemfile
142
+ - LICENSE.txt
143
+ - README.md
144
+ - Rakefile
145
+ - circle.yml
146
+ - config/mongoid2.yml
147
+ - config/mongoid3.yml
148
+ - config/mongoid4.yml
149
+ - gemfiles/mongoid2.gemfile
150
+ - gemfiles/mongoid2.gemfile.lock
151
+ - gemfiles/mongoid3.gemfile
152
+ - gemfiles/mongoid3.gemfile.lock
153
+ - gemfiles/mongoid4.gemfile
154
+ - gemfiles/mongoid4.gemfile.lock
155
+ - lib/quby/answer_repos/mongoid_repo.rb
156
+ - lib/quby/mongoid.rb
157
+ - lib/quby/mongoid/version.rb
158
+ - quby-mongoid.gemspec
159
+ - rubocop-todo.yml
160
+ - spec/fixtures/big.rb
161
+ - spec/quby/answer_repos/mongoid_repo_spec.rb
162
+ - spec/spec_helper.rb
163
+ homepage: ''
164
+ licenses:
165
+ - MIT
166
+ metadata: {}
167
+ post_install_message:
168
+ rdoc_options: []
169
+ require_paths:
170
+ - lib
171
+ required_ruby_version: !ruby/object:Gem::Requirement
172
+ requirements:
173
+ - - ">="
174
+ - !ruby/object:Gem::Version
175
+ version: '0'
176
+ required_rubygems_version: !ruby/object:Gem::Requirement
177
+ requirements:
178
+ - - ">="
179
+ - !ruby/object:Gem::Version
180
+ version: '0'
181
+ requirements: []
182
+ rubyforge_project:
183
+ rubygems_version: 2.2.2
184
+ signing_key:
185
+ specification_version: 4
186
+ summary: Mongoid database adapter for the Quby questionnaire engine
187
+ test_files:
188
+ - spec/fixtures/big.rb
189
+ - spec/quby/answer_repos/mongoid_repo_spec.rb
190
+ - spec/spec_helper.rb