muck-engine 3.3.18 → 3.4.0
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/app/controllers/admin/muck/base_controller.rb +1 -1
- data/lib/test/muck_factories.rb +280 -276
- data/muck-engine.gemspec +2 -2
- metadata +5 -5
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
3.
|
1
|
+
3.4.0
|
data/lib/test/muck_factories.rb
CHANGED
@@ -1,279 +1,283 @@
|
|
1
1
|
# This file defines factories for all muck related models. You must have the
|
2
2
|
# muck gem installed and the related migrations run for all of these to work.
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
160
|
-
|
161
|
-
|
162
|
-
|
163
|
-
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
-
|
168
|
-
|
169
|
-
|
170
|
-
|
171
|
-
|
172
|
-
|
173
|
-
|
174
|
-
|
175
|
-
|
176
|
-
|
177
|
-
|
178
|
-
|
179
|
-
|
180
|
-
|
181
|
-
|
182
|
-
|
183
|
-
|
184
|
-
|
185
|
-
|
186
|
-
|
187
|
-
|
188
|
-
|
189
|
-
|
190
|
-
|
191
|
-
|
192
|
-
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
|
202
|
-
|
203
|
-
|
204
|
-
|
205
|
-
|
206
|
-
|
207
|
-
|
208
|
-
|
209
|
-
|
210
|
-
|
211
|
-
|
212
|
-
|
213
|
-
|
214
|
-
|
215
|
-
|
216
|
-
|
217
|
-
|
218
|
-
|
219
|
-
|
220
|
-
|
221
|
-
|
222
|
-
|
223
|
-
|
224
|
-
|
225
|
-
|
226
|
-
|
227
|
-
|
228
|
-
|
229
|
-
|
230
|
-
|
231
|
-
|
232
|
-
|
233
|
-
|
234
|
-
|
235
|
-
|
236
|
-
|
237
|
-
|
238
|
-
|
239
|
-
|
240
|
-
|
241
|
-
|
242
|
-
|
243
|
-
|
244
|
-
|
245
|
-
|
246
|
-
|
247
|
-
|
248
|
-
|
249
|
-
|
250
|
-
|
251
|
-
|
252
|
-
|
253
|
-
|
254
|
-
|
255
|
-
|
256
|
-
|
257
|
-
|
258
|
-
|
259
|
-
|
260
|
-
|
261
|
-
|
262
|
-
|
263
|
-
|
264
|
-
|
265
|
-
|
266
|
-
|
267
|
-
|
268
|
-
|
269
|
-
|
270
|
-
|
271
|
-
|
272
|
-
|
273
|
-
|
274
|
-
|
275
|
-
|
276
|
-
|
277
|
-
|
278
|
-
|
3
|
+
FactoryGirl.define do
|
4
|
+
|
5
|
+
sequence :email do |n|
|
6
|
+
"somebody#{n}@example.com"
|
7
|
+
end
|
8
|
+
|
9
|
+
sequence :login do |n|
|
10
|
+
"inquire#{n}"
|
11
|
+
end
|
12
|
+
|
13
|
+
sequence :name do |n|
|
14
|
+
"a_name#{n}"
|
15
|
+
end
|
16
|
+
|
17
|
+
sequence :title do |n|
|
18
|
+
"a_title#{n}"
|
19
|
+
end
|
20
|
+
|
21
|
+
sequence :abbr do |n|
|
22
|
+
"abbr#{n}"
|
23
|
+
end
|
24
|
+
|
25
|
+
sequence :uri do |n|
|
26
|
+
"n#{n}.example.com"
|
27
|
+
end
|
28
|
+
|
29
|
+
sequence :description do |n|
|
30
|
+
"This is the description: #{n}"
|
31
|
+
end
|
32
|
+
|
33
|
+
sequence :locale do |n|
|
34
|
+
"a#{n}"
|
35
|
+
end
|
36
|
+
|
37
|
+
sequence :address do |n|
|
38
|
+
"#{n} West #{n} South"
|
39
|
+
end
|
40
|
+
|
41
|
+
factory :state do
|
42
|
+
name { Factory.next(:name) }
|
43
|
+
abbreviation { Factory.next(:abbr) }
|
44
|
+
country {|a| a.association(:country) }
|
45
|
+
end
|
46
|
+
|
47
|
+
factory :country do
|
48
|
+
name { Factory.next(:name) }
|
49
|
+
abbreviation { Factory.next(:abbr) }
|
50
|
+
end
|
51
|
+
|
52
|
+
factory :language do
|
53
|
+
name { Factory.next(:name) }
|
54
|
+
english_name { Factory.next(:name) }
|
55
|
+
locale { Factory.next(:locale) }
|
56
|
+
supported true
|
57
|
+
muck_raker_supported true
|
58
|
+
end
|
59
|
+
|
60
|
+
# This is used for tests within muck-engine. The language
|
61
|
+
# model is modified by migrations in other gems to include 'muck_raker_supported'
|
62
|
+
factory :unmodified_language, :class => Language do
|
63
|
+
name { Factory.next(:name) }
|
64
|
+
english_name { Factory.next(:name) }
|
65
|
+
locale { Factory.next(:locale) }
|
66
|
+
supported true
|
67
|
+
end
|
68
|
+
|
69
|
+
factory :user do
|
70
|
+
login { Factory.next(:login) }
|
71
|
+
email { Factory.next(:email) }
|
72
|
+
password 'inquire_pass'
|
73
|
+
password_confirmation 'inquire_pass'
|
74
|
+
first_name 'test'
|
75
|
+
last_name 'guy'
|
76
|
+
terms_of_service true
|
77
|
+
activated_at DateTime.now
|
78
|
+
end
|
79
|
+
|
80
|
+
factory :profile do
|
81
|
+
user {|a| a.association(:user)}
|
82
|
+
photo fixture_file_upload("#{::Rails.root}/public/images/profile_default.jpg", 'image/jpg')
|
83
|
+
location 'Jackson Hole, WY'
|
84
|
+
about 'A great person'
|
85
|
+
city 'Jackson Hole'
|
86
|
+
state {|a| a.association(:state)}
|
87
|
+
country {|a| a.association(:country)}
|
88
|
+
# language {|a| a.association(:language)}
|
89
|
+
policy 'a great policy'
|
90
|
+
end
|
91
|
+
|
92
|
+
factory :content_page do
|
93
|
+
creator {|a| a.association(:user)}
|
94
|
+
title { Factory.next(:name) }
|
95
|
+
body_raw { Factory.next(:description) }
|
96
|
+
end
|
97
|
+
|
98
|
+
factory :permission do
|
99
|
+
role {|a| a.association(:role)}
|
100
|
+
user {|a| a.association(:user)}
|
101
|
+
end
|
102
|
+
|
103
|
+
factory :role do
|
104
|
+
rolename { Factory.next(:name) }
|
105
|
+
end
|
106
|
+
|
107
|
+
factory :access_code do
|
108
|
+
code { Factory.next(:name) }
|
109
|
+
uses 0
|
110
|
+
unlimited false
|
111
|
+
expires_at { DateTime.now + 2.weeks }
|
112
|
+
use_limit 1
|
113
|
+
end
|
114
|
+
|
115
|
+
factory :access_code_request do
|
116
|
+
email { Factory.next(:email) }
|
117
|
+
end
|
118
|
+
|
119
|
+
factory :activity do
|
120
|
+
item {|a| a.association(:user)}
|
121
|
+
template ''
|
122
|
+
source {|a| a.association(:user)}
|
123
|
+
content ''
|
124
|
+
title ''
|
125
|
+
is_status_update false
|
126
|
+
is_public true
|
127
|
+
created_at DateTime.now
|
128
|
+
end
|
129
|
+
|
130
|
+
factory :activity_feed do
|
131
|
+
activity {|a| a.association(:activity)}
|
132
|
+
ownable {|a| a.association(:user)}
|
133
|
+
end
|
134
|
+
|
135
|
+
factory :comment do
|
136
|
+
body { Factory.next(:description) }
|
137
|
+
user {|a| a.association(:user)}
|
138
|
+
commentable {|a| a.association(:user)}
|
139
|
+
end
|
140
|
+
|
141
|
+
factory :share do
|
142
|
+
uri { Factory.next(:uri) }
|
143
|
+
title { Factory.next(:title) }
|
144
|
+
shared_by {|a| a.association(:user)}
|
145
|
+
end
|
146
|
+
|
147
|
+
factory :blog do
|
148
|
+
title { Factory.next(:title) }
|
149
|
+
blogable {|a| a.association(:user)}
|
150
|
+
end
|
151
|
+
|
152
|
+
factory :domain_theme do
|
153
|
+
name { Factory.next(:name) }
|
154
|
+
uri { Factory.next(:uri) }
|
155
|
+
end
|
156
|
+
|
157
|
+
factory :theme do
|
158
|
+
name { Factory.next(:name) }
|
159
|
+
end
|
160
|
+
|
161
|
+
factory :feed do
|
162
|
+
contributor { |a| a.association(:user) }
|
163
|
+
uri { Factory.next(:uri) }
|
164
|
+
display_uri { Factory.next(:uri) }
|
165
|
+
title { Factory.next(:title) }
|
166
|
+
short_title { Factory.next(:title) }
|
167
|
+
description { Factory.next(:description) }
|
168
|
+
top_tags { Factory.next(:name) }
|
169
|
+
priority 1
|
170
|
+
status 1
|
171
|
+
last_requested_at DateTime.now
|
172
|
+
last_harvested_at DateTime.now
|
173
|
+
harvest_interval 86400
|
174
|
+
failed_requests 0
|
175
|
+
harvested_from_display_uri { Factory.next(:uri) }
|
176
|
+
harvested_from_title { Factory.next(:title) }
|
177
|
+
harvested_from_short_title { Factory.next(:title) }
|
178
|
+
entries_count 0
|
179
|
+
default_language { |a| a.association(:language) }
|
180
|
+
default_grain_size 'unknown'
|
181
|
+
end
|
182
|
+
|
183
|
+
factory :entry do
|
184
|
+
feed { |a| a.association(:feed) }
|
185
|
+
permalink { Factory.next(:uri) }
|
186
|
+
author { Factory.next(:name) }
|
187
|
+
title { Factory.next(:title) }
|
188
|
+
description { Factory.next(:description) }
|
189
|
+
content { Factory.next(:description) }
|
190
|
+
unique_content { Factory.next(:description) }
|
191
|
+
published_at DateTime.now
|
192
|
+
entry_updated_at DateTime.now
|
193
|
+
harvested_at DateTime.now
|
194
|
+
language { |a| a.association(:language) }
|
195
|
+
direct_link { Factory.next(:uri) }
|
196
|
+
grain_size 'unknown'
|
197
|
+
end
|
198
|
+
|
199
|
+
factory :aggregation do
|
200
|
+
title { Factory.next(:name) }
|
201
|
+
terms { Factory.next(:name) }
|
202
|
+
description { Factory.next(:description) }
|
203
|
+
ownable {|a| a.association(:user)}
|
204
|
+
end
|
205
|
+
|
206
|
+
factory :aggregation_feed do
|
207
|
+
feed {|a| a.association(:feed)}
|
208
|
+
aggregation {|a| a.association(:aggregation)}
|
209
|
+
end
|
210
|
+
|
211
|
+
factory :oai_endpoint do
|
212
|
+
contributor { |a| a.association(:user) }
|
213
|
+
uri { Factory.next(:uri) }
|
214
|
+
display_uri { Factory.next(:uri) }
|
215
|
+
title { Factory.next(:title) }
|
216
|
+
short_title { Factory.next(:title) }
|
217
|
+
status 1
|
218
|
+
end
|
219
|
+
|
220
|
+
factory :service do
|
221
|
+
uri { Factory.next(:uri) }
|
222
|
+
name { Factory.next(:name) }
|
223
|
+
service_category { |a| a.association(:service_category) }
|
224
|
+
end
|
225
|
+
|
226
|
+
factory :service_category do
|
227
|
+
name { Factory.next(:name) }
|
228
|
+
end
|
229
|
+
|
230
|
+
factory :content do
|
231
|
+
creator { |a| a.association(:user) }
|
232
|
+
title { Factory.next(:title) }
|
233
|
+
body_raw { Factory.next(:description) }
|
234
|
+
is_public true
|
235
|
+
locale 'en'
|
236
|
+
end
|
237
|
+
|
238
|
+
factory :content_translation do
|
239
|
+
content { |a| a.association(:content) }
|
240
|
+
title { Factory.next(:title) }
|
241
|
+
body { Factory.next(:description) }
|
242
|
+
locale 'en'
|
243
|
+
end
|
244
|
+
|
245
|
+
factory :content_permission do
|
246
|
+
content { |a| a.association(:content) }
|
247
|
+
user { |a| a.association(:user) }
|
248
|
+
end
|
249
|
+
|
250
|
+
factory :invitee do
|
251
|
+
email { Factory.next(:email) }
|
252
|
+
end
|
253
|
+
|
254
|
+
factory :group do
|
255
|
+
creator {|a| a.association(:user)}
|
256
|
+
name { Factory.next(:name) }
|
257
|
+
description { Factory.next(:description) }
|
258
|
+
member_count 0
|
259
|
+
end
|
260
|
+
|
261
|
+
factory :membership_request do
|
262
|
+
group {|a| a.association(:group)}
|
263
|
+
user {|a| a.association(:user)}
|
264
|
+
end
|
265
|
+
|
266
|
+
factory :membership do
|
267
|
+
group {|a| a.association(:group)}
|
268
|
+
user {|a| a.association(:user)}
|
269
|
+
banned false
|
270
|
+
role "member"
|
271
|
+
end
|
272
|
+
|
273
|
+
factory :authentication do
|
274
|
+
authenticatable {|a| a.association(:user)}
|
275
|
+
provider 'twitter'
|
276
|
+
name { Factory.next(:name) }
|
277
|
+
uid { Factory.next(:uri) }
|
278
|
+
token { Factory.next(:uri) }
|
279
|
+
secret { Factory.next(:uri) }
|
280
|
+
raw_auth { Factory.next(:description) }
|
281
|
+
end
|
282
|
+
|
279
283
|
end
|
data/muck-engine.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = "muck-engine"
|
8
|
-
s.version = "3.
|
8
|
+
s.version = "3.4.0"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Justin Ball", "Joel Duffin"]
|
12
|
-
s.date = "2011-
|
12
|
+
s.date = "2011-10-07"
|
13
13
|
s.description = "The base engine for the muck system. Contains common tables, custom for, css and javascript."
|
14
14
|
s.email = "justin@tatemae.com"
|
15
15
|
s.extra_rdoc_files = [
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: muck-engine
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 23
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 3
|
8
|
-
-
|
9
|
-
-
|
10
|
-
version: 3.
|
8
|
+
- 4
|
9
|
+
- 0
|
10
|
+
version: 3.4.0
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Justin Ball
|
@@ -16,7 +16,7 @@ autorequire:
|
|
16
16
|
bindir: bin
|
17
17
|
cert_chain: []
|
18
18
|
|
19
|
-
date: 2011-
|
19
|
+
date: 2011-10-07 00:00:00 Z
|
20
20
|
dependencies:
|
21
21
|
- !ruby/object:Gem::Dependency
|
22
22
|
version_requirements: &id001 !ruby/object:Gem::Requirement
|