locomotivecms_wagon 1.5.8 → 2.0.0.pre.alpha
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +4 -1
- data/.rspec +0 -1
- data/Gemfile +17 -2
- data/README.md +2 -6
- data/Rakefile +3 -20
- data/lib/locomotive/wagon/cli.rb +34 -39
- data/lib/locomotive/wagon/commands/authenticate_command.rb +65 -0
- data/lib/locomotive/wagon/commands/concerns/api_concern.rb +57 -0
- data/lib/locomotive/wagon/commands/concerns/deploy_file_concern.rb +32 -0
- data/lib/locomotive/wagon/commands/concerns/instrumentation_concern.rb +16 -0
- data/lib/locomotive/wagon/commands/concerns/netrc_concern.rb +21 -0
- data/lib/locomotive/wagon/commands/concerns/steam_concern.rb +24 -0
- data/lib/locomotive/wagon/commands/generate_command.rb +29 -0
- data/lib/locomotive/wagon/commands/init_command.rb +19 -0
- data/lib/locomotive/wagon/commands/loggers/push_logger.rb +59 -0
- data/lib/locomotive/wagon/commands/push_command.rb +116 -0
- data/lib/locomotive/wagon/commands/push_sub_commands/push_base_command.rb +68 -0
- data/lib/locomotive/wagon/commands/push_sub_commands/push_content_assets_command.rb +54 -0
- data/lib/locomotive/wagon/commands/push_sub_commands/push_content_entries_command.rb +85 -0
- data/lib/locomotive/wagon/commands/push_sub_commands/push_content_types_command.rb +70 -0
- data/lib/locomotive/wagon/commands/push_sub_commands/push_pages_command.rb +71 -0
- data/lib/locomotive/wagon/commands/push_sub_commands/push_snippets_command.rb +23 -0
- data/lib/locomotive/wagon/commands/push_sub_commands/push_theme_assets_command.rb +70 -0
- data/lib/locomotive/wagon/commands/push_sub_commands/push_translations_command.rb +23 -0
- data/lib/locomotive/wagon/commands/serve_command.rb +131 -0
- data/lib/locomotive/wagon/decorators/concerns/persist_assets_concern.rb +20 -0
- data/lib/locomotive/wagon/decorators/concerns/to_hash_concern.rb +25 -0
- data/lib/locomotive/wagon/decorators/content_asset_decorator.rb +29 -0
- data/lib/locomotive/wagon/decorators/content_entry_decorator.rb +100 -0
- data/lib/locomotive/wagon/decorators/content_type_decorator.rb +78 -0
- data/lib/locomotive/wagon/decorators/content_type_field_decorator.rb +76 -0
- data/lib/locomotive/wagon/decorators/editable_element_decorator.rb +32 -0
- data/lib/locomotive/wagon/decorators/page_decorator.rb +81 -0
- data/lib/locomotive/wagon/decorators/site_decorator.rb +25 -0
- data/lib/locomotive/wagon/decorators/snippet_decorator.rb +29 -0
- data/lib/locomotive/wagon/decorators/theme_asset_decorator.rb +53 -0
- data/lib/locomotive/wagon/decorators/translation_decorator.rb +19 -0
- data/lib/locomotive/wagon/exceptions.rb +3 -55
- data/lib/locomotive/wagon/generators/site/unzip.rb +2 -2
- data/lib/locomotive/wagon/tools/deployment_connection.rb +120 -0
- data/lib/locomotive/wagon/tools/hosting_api.rb +117 -0
- data/lib/locomotive/wagon/tools/listen.rb +51 -0
- data/lib/locomotive/wagon/{misc → tools}/livereload.rb +5 -3
- data/lib/locomotive/wagon/{misc → tools}/tcp_port.rb +0 -0
- data/lib/locomotive/wagon/{misc → tools}/thor.rb +0 -0
- data/lib/locomotive/wagon/version.rb +1 -1
- data/lib/locomotive/wagon.rb +34 -162
- data/locomotivecms_wagon.gemspec +11 -24
- data/spec/fixtures/cassettes/authenticate.yml +425 -0
- data/spec/fixtures/cassettes/push.yml +34737 -0
- data/spec/fixtures/default/app/views/pages/events.liquid.haml +2 -1
- data/spec/fixtures/default/app/views/pages/index.liquid.haml +3 -2
- data/spec/fixtures/default/app/views/pages/layouts/simple.liquid.haml +1 -1
- data/spec/fixtures/default/app/views/snippets/footer.liquid.haml +1 -1
- data/spec/fixtures/default/app/views/snippets/song.liquid +3 -3
- data/spec/fixtures/default/config/site.yml +2 -4
- data/spec/fixtures/default/data/events.yml +3 -2
- data/spec/fixtures/default/data/songs.yml +1 -1
- data/spec/integration/cli_spec.rb +35 -12
- data/spec/integration/commands/authenticate_command_spec.rb +60 -0
- data/spec/integration/commands/push_command_spec.rb +55 -0
- data/spec/integration/generators/page_spec.rb +9 -9
- data/spec/integration/generators/relationship_spec.rb +6 -6
- data/spec/integration/integration_helper.rb +11 -11
- data/spec/integration/sites_spec.rb +48 -48
- data/spec/spec_helper.rb +3 -4
- data/spec/support/api_settings.rb +5 -0
- data/spec/support/helpers.rb +6 -19
- data/spec/support/pry.rb +4 -0
- data/spec/support/thor.rb +12 -0
- data/spec/support/vcr.rb +10 -0
- data/spec/unit/decorators/site_decorator_spec.rb +36 -0
- metadata +88 -309
- data/lib/locomotive/wagon/liquid/drops/base.rb +0 -49
- data/lib/locomotive/wagon/liquid/drops/content_entry.rb +0 -49
- data/lib/locomotive/wagon/liquid/drops/content_types.rb +0 -119
- data/lib/locomotive/wagon/liquid/drops/page.rb +0 -84
- data/lib/locomotive/wagon/liquid/drops/session_proxy.rb +0 -18
- data/lib/locomotive/wagon/liquid/drops/site.rb +0 -26
- data/lib/locomotive/wagon/liquid/errors.rb +0 -17
- data/lib/locomotive/wagon/liquid/filters/date.rb +0 -136
- data/lib/locomotive/wagon/liquid/filters/html.rb +0 -188
- data/lib/locomotive/wagon/liquid/filters/misc.rb +0 -49
- data/lib/locomotive/wagon/liquid/filters/resize.rb +0 -18
- data/lib/locomotive/wagon/liquid/filters/text.rb +0 -55
- data/lib/locomotive/wagon/liquid/filters/translate.rb +0 -28
- data/lib/locomotive/wagon/liquid/patches.rb +0 -47
- data/lib/locomotive/wagon/liquid/scopeable.rb +0 -151
- data/lib/locomotive/wagon/liquid/tags/consume.rb +0 -100
- data/lib/locomotive/wagon/liquid/tags/csrf.rb +0 -34
- data/lib/locomotive/wagon/liquid/tags/editable/base.rb +0 -50
- data/lib/locomotive/wagon/liquid/tags/editable/control.rb +0 -19
- data/lib/locomotive/wagon/liquid/tags/editable/file.rb +0 -15
- data/lib/locomotive/wagon/liquid/tags/editable/long_text.rb +0 -15
- data/lib/locomotive/wagon/liquid/tags/editable/short_text.rb +0 -20
- data/lib/locomotive/wagon/liquid/tags/editable/text.rb +0 -15
- data/lib/locomotive/wagon/liquid/tags/editable.rb +0 -6
- data/lib/locomotive/wagon/liquid/tags/extends.rb +0 -25
- data/lib/locomotive/wagon/liquid/tags/fetch_page.rb +0 -41
- data/lib/locomotive/wagon/liquid/tags/google_analytics.rb +0 -28
- data/lib/locomotive/wagon/liquid/tags/hybrid.rb +0 -27
- data/lib/locomotive/wagon/liquid/tags/inline_editor.rb +0 -16
- data/lib/locomotive/wagon/liquid/tags/link_to.rb +0 -56
- data/lib/locomotive/wagon/liquid/tags/locale_switcher.rb +0 -106
- data/lib/locomotive/wagon/liquid/tags/model_form.rb +0 -67
- data/lib/locomotive/wagon/liquid/tags/nav.rb +0 -287
- data/lib/locomotive/wagon/liquid/tags/paginate.rb +0 -105
- data/lib/locomotive/wagon/liquid/tags/path_helper.rb +0 -97
- data/lib/locomotive/wagon/liquid/tags/path_to.rb +0 -36
- data/lib/locomotive/wagon/liquid/tags/seo.rb +0 -74
- data/lib/locomotive/wagon/liquid/tags/session_assign.rb +0 -41
- data/lib/locomotive/wagon/liquid/tags/snippet.rb +0 -63
- data/lib/locomotive/wagon/liquid/tags/with_scope.rb +0 -48
- data/lib/locomotive/wagon/liquid.rb +0 -21
- data/lib/locomotive/wagon/listen.rb +0 -65
- data/lib/locomotive/wagon/logger.rb +0 -58
- data/lib/locomotive/wagon/misc/better_errors.rb +0 -70
- data/lib/locomotive/wagon/misc/core_ext.rb +0 -62
- data/lib/locomotive/wagon/misc/deployment_connection.rb +0 -120
- data/lib/locomotive/wagon/misc/dragonfly.rb +0 -78
- data/lib/locomotive/wagon/misc/haml.rb +0 -15
- data/lib/locomotive/wagon/misc/hosting_api.rb +0 -117
- data/lib/locomotive/wagon/misc/httparty.rb +0 -55
- data/lib/locomotive/wagon/misc/i18n.rb +0 -2
- data/lib/locomotive/wagon/misc/markdown.rb +0 -27
- data/lib/locomotive/wagon/misc/mounter.rb +0 -32
- data/lib/locomotive/wagon/misc/will_paginate.rb +0 -16
- data/lib/locomotive/wagon/misc.rb +0 -9
- data/lib/locomotive/wagon/server/dynamic_assets.rb +0 -33
- data/lib/locomotive/wagon/server/entry_submission.rb +0 -151
- data/lib/locomotive/wagon/server/favicon.rb +0 -17
- data/lib/locomotive/wagon/server/locale.rb +0 -42
- data/lib/locomotive/wagon/server/logging.rb +0 -32
- data/lib/locomotive/wagon/server/middleware.rb +0 -63
- data/lib/locomotive/wagon/server/page.rb +0 -67
- data/lib/locomotive/wagon/server/path.rb +0 -34
- data/lib/locomotive/wagon/server/renderer.rb +0 -118
- data/lib/locomotive/wagon/server/templatized_page.rb +0 -32
- data/lib/locomotive/wagon/server/timezone.rb +0 -18
- data/lib/locomotive/wagon/server.rb +0 -86
- data/lib/locomotive/wagon/standalone_server.rb +0 -28
- data/locales/de.yml +0 -157
- data/locales/en.yml +0 -189
- data/locales/es.yml +0 -133
- data/locales/et.yml +0 -154
- data/locales/fr.yml +0 -148
- data/locales/it.yml +0 -155
- data/locales/nb.yml +0 -191
- data/locales/nl.yml +0 -160
- data/locales/pl.yml +0 -203
- data/locales/pt-BR.yml +0 -139
- data/locales/ru.yml +0 -224
- data/spec/integration/server/basic_spec.rb +0 -169
- data/spec/integration/server/contact_form_spec.rb +0 -111
- data/spec/integration/server/liquid_spec.rb +0 -98
- data/spec/integration/server/new_contact_form_spec.rb +0 -67
- data/spec/integration/server/with_scope_spec.rb +0 -30
- data/spec/unit/locomotive/wagon/liquid/drops/page_spec.rb +0 -41
@@ -0,0 +1,425 @@
|
|
1
|
+
---
|
2
|
+
http_interactions:
|
3
|
+
- request:
|
4
|
+
method: post
|
5
|
+
uri: http://localhost:3000/locomotive/api/v3/tokens.json?email=john@doe.net&password=asimplepassword
|
6
|
+
body:
|
7
|
+
encoding: UTF-8
|
8
|
+
string: ''
|
9
|
+
headers:
|
10
|
+
Accept:
|
11
|
+
- application/json
|
12
|
+
Content-Length:
|
13
|
+
- '0'
|
14
|
+
Accept-Encoding:
|
15
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
16
|
+
User-Agent:
|
17
|
+
- Ruby
|
18
|
+
response:
|
19
|
+
status:
|
20
|
+
code: 401
|
21
|
+
message: Unauthorized
|
22
|
+
headers:
|
23
|
+
Content-Type:
|
24
|
+
- application/json
|
25
|
+
X-Error-Detail:
|
26
|
+
- Invalid email or password.
|
27
|
+
Content-Length:
|
28
|
+
- '40'
|
29
|
+
Cache-Control:
|
30
|
+
- no-cache
|
31
|
+
X-Request-Id:
|
32
|
+
- fb0a7852-232e-4c8b-8ab3-456cfbab2078
|
33
|
+
X-Runtime:
|
34
|
+
- '0.664468'
|
35
|
+
Connection:
|
36
|
+
- keep-alive
|
37
|
+
Server:
|
38
|
+
- thin
|
39
|
+
body:
|
40
|
+
encoding: UTF-8
|
41
|
+
string: '{"message":"Invalid email or password."}'
|
42
|
+
http_version:
|
43
|
+
recorded_at: Wed, 08 Apr 2015 09:48:56 GMT
|
44
|
+
- request:
|
45
|
+
method: post
|
46
|
+
uri: http://localhost:3000/locomotive/api/v3/my_account.json?account%5Bemail%5D=john@doe.net&account%5Bname%5D=John&account%5Bpassword%5D=asimplepassword
|
47
|
+
body:
|
48
|
+
encoding: UTF-8
|
49
|
+
string: ''
|
50
|
+
headers:
|
51
|
+
Accept:
|
52
|
+
- application/json
|
53
|
+
Content-Length:
|
54
|
+
- '0'
|
55
|
+
Accept-Encoding:
|
56
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
57
|
+
User-Agent:
|
58
|
+
- Ruby
|
59
|
+
response:
|
60
|
+
status:
|
61
|
+
code: 201
|
62
|
+
message: Created
|
63
|
+
headers:
|
64
|
+
Content-Type:
|
65
|
+
- application/json
|
66
|
+
Content-Length:
|
67
|
+
- '411'
|
68
|
+
Etag:
|
69
|
+
- W/"d5f22e786ad106187b381c8d685a3e92"
|
70
|
+
Cache-Control:
|
71
|
+
- max-age=0, private, must-revalidate
|
72
|
+
X-Request-Id:
|
73
|
+
- aee412b7-82df-4978-bd1f-f8f3314ead2d
|
74
|
+
X-Runtime:
|
75
|
+
- '0.061719'
|
76
|
+
Connection:
|
77
|
+
- keep-alive
|
78
|
+
Server:
|
79
|
+
- thin
|
80
|
+
body:
|
81
|
+
encoding: UTF-8
|
82
|
+
string: '{"_id":"5524f98864696407ae100000","created_at":"2015-04-08T09:48:56Z","updated_at":"2015-04-08T09:48:56Z","name":"John","email":"john@doe.net","locale":"en","encrypted_password":"39f8358678144ef6715b9420a7a65706552272fb","password_salt":"sV9PWhfxDRy4b1pj6jLd","api_key":"8e5586fe34c5628d8e1ace2a8a750ae922ae2884","super_admin":false,"password":"asimplepassword","password_confirmation":null,"local_admin":false}'
|
83
|
+
http_version:
|
84
|
+
recorded_at: Wed, 08 Apr 2015 09:48:56 GMT
|
85
|
+
- request:
|
86
|
+
method: post
|
87
|
+
uri: http://localhost:3000/locomotive/api/v3/tokens.json?email=admin@locomotivecms.com&password=locomotive
|
88
|
+
body:
|
89
|
+
encoding: UTF-8
|
90
|
+
string: ''
|
91
|
+
headers:
|
92
|
+
Accept:
|
93
|
+
- application/json
|
94
|
+
Content-Length:
|
95
|
+
- '0'
|
96
|
+
Accept-Encoding:
|
97
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
98
|
+
User-Agent:
|
99
|
+
- Ruby
|
100
|
+
response:
|
101
|
+
status:
|
102
|
+
code: 201
|
103
|
+
message: Created
|
104
|
+
headers:
|
105
|
+
Content-Type:
|
106
|
+
- application/json
|
107
|
+
Content-Length:
|
108
|
+
- '32'
|
109
|
+
Etag:
|
110
|
+
- W/"333586de1d24c181814b7fd1fc093943"
|
111
|
+
Cache-Control:
|
112
|
+
- max-age=0, private, must-revalidate
|
113
|
+
X-Request-Id:
|
114
|
+
- 7b0c6596-42b7-4466-94a3-5347b7fc9234
|
115
|
+
X-Runtime:
|
116
|
+
- '0.019200'
|
117
|
+
Connection:
|
118
|
+
- keep-alive
|
119
|
+
Server:
|
120
|
+
- thin
|
121
|
+
body:
|
122
|
+
encoding: UTF-8
|
123
|
+
string: '{"token":"by7uUTBWyg5LzGTfyykK"}'
|
124
|
+
http_version:
|
125
|
+
recorded_at: Wed, 08 Apr 2015 10:50:39 GMT
|
126
|
+
- request:
|
127
|
+
method: get
|
128
|
+
uri: http://localhost:3000/locomotive/api/v3/my_account.json?auth_token=by7uUTBWyg5LzGTfyykK
|
129
|
+
body:
|
130
|
+
encoding: US-ASCII
|
131
|
+
string: ''
|
132
|
+
headers:
|
133
|
+
Accept:
|
134
|
+
- application/json
|
135
|
+
X-Locomotive-Account-Email:
|
136
|
+
- admin@locomotivecms.com
|
137
|
+
X-Locomotive-Account-Token:
|
138
|
+
- by7uUTBWyg5LzGTfyykK
|
139
|
+
Accept-Encoding:
|
140
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
141
|
+
User-Agent:
|
142
|
+
- Ruby
|
143
|
+
response:
|
144
|
+
status:
|
145
|
+
code: 200
|
146
|
+
message: OK
|
147
|
+
headers:
|
148
|
+
Content-Type:
|
149
|
+
- application/json
|
150
|
+
Content-Length:
|
151
|
+
- '409'
|
152
|
+
Etag:
|
153
|
+
- W/"de9362bbb5bdda2f08c588cb8bccc53e"
|
154
|
+
Cache-Control:
|
155
|
+
- max-age=0, private, must-revalidate
|
156
|
+
X-Request-Id:
|
157
|
+
- 38706597-257a-401c-9769-c8b9d27c237a
|
158
|
+
X-Runtime:
|
159
|
+
- '0.036344'
|
160
|
+
Connection:
|
161
|
+
- keep-alive
|
162
|
+
Server:
|
163
|
+
- thin
|
164
|
+
body:
|
165
|
+
encoding: UTF-8
|
166
|
+
string: '{"_id":"5524f99e646964184d000000","created_at":"2015-04-08T09:49:18Z","updated_at":"2015-04-08T09:49:18Z","name":"Admin","email":"admin@locomotivecms.com","locale":"en","encrypted_password":"a8f4f98e0c5a2578d750112f3df78338fa97e198","password_salt":"bQipQKDzKFhXnpXEYxoh","api_key":"d49cd50f6f0d2b163f48fc73cb249f0244c37074","super_admin":false,"password":null,"password_confirmation":null,"local_admin":true}'
|
167
|
+
http_version:
|
168
|
+
recorded_at: Wed, 08 Apr 2015 10:50:39 GMT
|
169
|
+
- request:
|
170
|
+
method: get
|
171
|
+
uri: http://localhost:3000/locomotive/api/v3/my_account.json?auth_token=by7uUTBWyg5LzGTfyykK
|
172
|
+
body:
|
173
|
+
encoding: US-ASCII
|
174
|
+
string: ''
|
175
|
+
headers:
|
176
|
+
Accept:
|
177
|
+
- application/json
|
178
|
+
X-Locomotive-Account-Email:
|
179
|
+
- admin@locomotivecms.com
|
180
|
+
X-Locomotive-Account-Token:
|
181
|
+
- by7uUTBWyg5LzGTfyykK
|
182
|
+
Accept-Encoding:
|
183
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
184
|
+
User-Agent:
|
185
|
+
- Ruby
|
186
|
+
response:
|
187
|
+
status:
|
188
|
+
code: 200
|
189
|
+
message: OK
|
190
|
+
headers:
|
191
|
+
Content-Type:
|
192
|
+
- application/json
|
193
|
+
Content-Length:
|
194
|
+
- '409'
|
195
|
+
Etag:
|
196
|
+
- W/"de9362bbb5bdda2f08c588cb8bccc53e"
|
197
|
+
Cache-Control:
|
198
|
+
- max-age=0, private, must-revalidate
|
199
|
+
X-Request-Id:
|
200
|
+
- 92225521-e544-4a18-a1b5-7f0c45177ad0
|
201
|
+
X-Runtime:
|
202
|
+
- '0.017949'
|
203
|
+
Connection:
|
204
|
+
- keep-alive
|
205
|
+
Server:
|
206
|
+
- thin
|
207
|
+
body:
|
208
|
+
encoding: UTF-8
|
209
|
+
string: '{"_id":"5524f99e646964184d000000","created_at":"2015-04-08T09:49:18Z","updated_at":"2015-04-08T09:49:18Z","name":"Admin","email":"admin@locomotivecms.com","locale":"en","encrypted_password":"a8f4f98e0c5a2578d750112f3df78338fa97e198","password_salt":"bQipQKDzKFhXnpXEYxoh","api_key":"d49cd50f6f0d2b163f48fc73cb249f0244c37074","super_admin":false,"password":null,"password_confirmation":null,"local_admin":true}'
|
210
|
+
http_version:
|
211
|
+
recorded_at: Wed, 08 Apr 2015 10:50:39 GMT
|
212
|
+
- request:
|
213
|
+
method: post
|
214
|
+
uri: http://localhost:3000/locomotive/api/v3/tokens.json
|
215
|
+
body:
|
216
|
+
encoding: UTF-8
|
217
|
+
string: email=john%40doe.net&password=asimplepassword
|
218
|
+
headers:
|
219
|
+
Accept:
|
220
|
+
- application/json
|
221
|
+
Content-Type:
|
222
|
+
- application/x-www-form-urlencoded
|
223
|
+
Accept-Encoding:
|
224
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
225
|
+
User-Agent:
|
226
|
+
- Ruby
|
227
|
+
response:
|
228
|
+
status:
|
229
|
+
code: 401
|
230
|
+
message: Unauthorized
|
231
|
+
headers:
|
232
|
+
Content-Type:
|
233
|
+
- application/json
|
234
|
+
X-Error-Detail:
|
235
|
+
- Invalid email or password.
|
236
|
+
Content-Length:
|
237
|
+
- '40'
|
238
|
+
Cache-Control:
|
239
|
+
- no-cache
|
240
|
+
X-Request-Id:
|
241
|
+
- a6c974fb-44dc-46e1-9c36-4fbecb291f3b
|
242
|
+
X-Runtime:
|
243
|
+
- '0.444182'
|
244
|
+
Connection:
|
245
|
+
- keep-alive
|
246
|
+
Server:
|
247
|
+
- thin
|
248
|
+
body:
|
249
|
+
encoding: UTF-8
|
250
|
+
string: '{"message":"Invalid email or password."}'
|
251
|
+
http_version:
|
252
|
+
recorded_at: Sun, 19 Apr 2015 21:26:18 GMT
|
253
|
+
- request:
|
254
|
+
method: post
|
255
|
+
uri: http://localhost:3000/locomotive/api/v3/my_account.json
|
256
|
+
body:
|
257
|
+
encoding: UTF-8
|
258
|
+
string: account%5Bemail%5D=john%40doe.net&account%5Bname%5D=John&account%5Bpassword%5D=asimplepassword
|
259
|
+
headers:
|
260
|
+
Accept:
|
261
|
+
- application/json
|
262
|
+
Content-Type:
|
263
|
+
- application/x-www-form-urlencoded
|
264
|
+
Accept-Encoding:
|
265
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
266
|
+
User-Agent:
|
267
|
+
- Ruby
|
268
|
+
response:
|
269
|
+
status:
|
270
|
+
code: 201
|
271
|
+
message: Created
|
272
|
+
headers:
|
273
|
+
Content-Type:
|
274
|
+
- application/json
|
275
|
+
Content-Length:
|
276
|
+
- '250'
|
277
|
+
Etag:
|
278
|
+
- W/"7f1ccfe9ba64fa9c9fe9e3cc62a4a6ae"
|
279
|
+
Cache-Control:
|
280
|
+
- max-age=0, private, must-revalidate
|
281
|
+
X-Request-Id:
|
282
|
+
- 7d9b6b49-14b6-452b-ad41-448ccd3030da
|
283
|
+
X-Runtime:
|
284
|
+
- '0.060605'
|
285
|
+
Connection:
|
286
|
+
- keep-alive
|
287
|
+
Server:
|
288
|
+
- thin
|
289
|
+
body:
|
290
|
+
encoding: UTF-8
|
291
|
+
string: '{"_id":"55341d7a64696402c1620000","created_at":"2015-04-19T21:26:18Z","updated_at":"2015-04-19T21:26:18Z","name":"John","email":"john@doe.net","locale":"en","api_key":"f4aabd29e179e2dea96d5f50e8570b06322c79d6","super_admin":false,"local_admin":false}'
|
292
|
+
http_version:
|
293
|
+
recorded_at: Sun, 19 Apr 2015 21:26:18 GMT
|
294
|
+
- request:
|
295
|
+
method: post
|
296
|
+
uri: http://localhost:3000/locomotive/api/v3/tokens.json
|
297
|
+
body:
|
298
|
+
encoding: UTF-8
|
299
|
+
string: email=admin%40locomotivecms.com&password=locomotive
|
300
|
+
headers:
|
301
|
+
Accept:
|
302
|
+
- application/json
|
303
|
+
Content-Type:
|
304
|
+
- application/x-www-form-urlencoded
|
305
|
+
Accept-Encoding:
|
306
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
307
|
+
User-Agent:
|
308
|
+
- Ruby
|
309
|
+
response:
|
310
|
+
status:
|
311
|
+
code: 201
|
312
|
+
message: Created
|
313
|
+
headers:
|
314
|
+
Content-Type:
|
315
|
+
- application/json
|
316
|
+
Content-Length:
|
317
|
+
- '32'
|
318
|
+
Etag:
|
319
|
+
- W/"d1f7b30db41123dbdfabce85ebf9a043"
|
320
|
+
Cache-Control:
|
321
|
+
- max-age=0, private, must-revalidate
|
322
|
+
X-Request-Id:
|
323
|
+
- f68a6e28-a329-4837-9717-e1bf3dffcb4d
|
324
|
+
X-Runtime:
|
325
|
+
- '0.015913'
|
326
|
+
Connection:
|
327
|
+
- keep-alive
|
328
|
+
Server:
|
329
|
+
- thin
|
330
|
+
body:
|
331
|
+
encoding: UTF-8
|
332
|
+
string: '{"token":"B1UseoZ1BSQUr86t5-Kz"}'
|
333
|
+
http_version:
|
334
|
+
recorded_at: Sun, 19 Apr 2015 21:26:18 GMT
|
335
|
+
- request:
|
336
|
+
method: get
|
337
|
+
uri: http://localhost:3000/locomotive/api/v3/my_account.json
|
338
|
+
body:
|
339
|
+
encoding: UTF-8
|
340
|
+
string: auth_token=B1UseoZ1BSQUr86t5-Kz
|
341
|
+
headers:
|
342
|
+
Accept:
|
343
|
+
- application/json
|
344
|
+
X-Locomotive-Account-Email:
|
345
|
+
- admin@locomotivecms.com
|
346
|
+
X-Locomotive-Account-Token:
|
347
|
+
- B1UseoZ1BSQUr86t5-Kz
|
348
|
+
Content-Type:
|
349
|
+
- application/x-www-form-urlencoded
|
350
|
+
Accept-Encoding:
|
351
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
352
|
+
User-Agent:
|
353
|
+
- Ruby
|
354
|
+
response:
|
355
|
+
status:
|
356
|
+
code: 200
|
357
|
+
message: OK
|
358
|
+
headers:
|
359
|
+
Content-Type:
|
360
|
+
- application/json
|
361
|
+
Content-Length:
|
362
|
+
- '261'
|
363
|
+
Etag:
|
364
|
+
- W/"294f1e257d98163da949834493fbbf45"
|
365
|
+
Cache-Control:
|
366
|
+
- max-age=0, private, must-revalidate
|
367
|
+
X-Request-Id:
|
368
|
+
- ce060fe8-b9b2-47f5-9b85-7378ebe75007
|
369
|
+
X-Runtime:
|
370
|
+
- '0.031785'
|
371
|
+
Connection:
|
372
|
+
- keep-alive
|
373
|
+
Server:
|
374
|
+
- thin
|
375
|
+
body:
|
376
|
+
encoding: UTF-8
|
377
|
+
string: '{"_id":"5533ee1d6469643196000000","created_at":"2015-04-19T18:04:13Z","updated_at":"2015-04-19T18:04:13Z","name":"Admin","email":"admin@locomotivecms.com","locale":"en","api_key":"d49cd50f6f0d2b163f48fc73cb249f0244c37074","super_admin":false,"local_admin":true}'
|
378
|
+
http_version:
|
379
|
+
recorded_at: Sun, 19 Apr 2015 21:26:18 GMT
|
380
|
+
- request:
|
381
|
+
method: get
|
382
|
+
uri: http://localhost:3000/locomotive/api/v3/my_account.json
|
383
|
+
body:
|
384
|
+
encoding: UTF-8
|
385
|
+
string: auth_token=B1UseoZ1BSQUr86t5-Kz
|
386
|
+
headers:
|
387
|
+
Accept:
|
388
|
+
- application/json
|
389
|
+
X-Locomotive-Account-Email:
|
390
|
+
- admin@locomotivecms.com
|
391
|
+
X-Locomotive-Account-Token:
|
392
|
+
- B1UseoZ1BSQUr86t5-Kz
|
393
|
+
Content-Type:
|
394
|
+
- application/x-www-form-urlencoded
|
395
|
+
Accept-Encoding:
|
396
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
397
|
+
User-Agent:
|
398
|
+
- Ruby
|
399
|
+
response:
|
400
|
+
status:
|
401
|
+
code: 200
|
402
|
+
message: OK
|
403
|
+
headers:
|
404
|
+
Content-Type:
|
405
|
+
- application/json
|
406
|
+
Content-Length:
|
407
|
+
- '261'
|
408
|
+
Etag:
|
409
|
+
- W/"294f1e257d98163da949834493fbbf45"
|
410
|
+
Cache-Control:
|
411
|
+
- max-age=0, private, must-revalidate
|
412
|
+
X-Request-Id:
|
413
|
+
- 4ce9cefd-14b4-4ed2-8e35-b66e2ec9e1ec
|
414
|
+
X-Runtime:
|
415
|
+
- '0.016007'
|
416
|
+
Connection:
|
417
|
+
- keep-alive
|
418
|
+
Server:
|
419
|
+
- thin
|
420
|
+
body:
|
421
|
+
encoding: UTF-8
|
422
|
+
string: '{"_id":"5533ee1d6469643196000000","created_at":"2015-04-19T18:04:13Z","updated_at":"2015-04-19T18:04:13Z","name":"Admin","email":"admin@locomotivecms.com","locale":"en","api_key":"d49cd50f6f0d2b163f48fc73cb249f0244c37074","super_admin":false,"local_admin":true}'
|
423
|
+
http_version:
|
424
|
+
recorded_at: Sun, 19 Apr 2015 21:26:18 GMT
|
425
|
+
recorded_with: VCR 2.9.3
|