poptart 0.0.13 → 0.0.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.ruby-version +1 -1
- data/lib/poptart.rb +1 -4
- data/lib/poptart/link.rb +9 -0
- data/lib/poptart/model.rb +13 -29
- data/lib/poptart/question.rb +21 -17
- data/lib/poptart/root.rb +10 -1
- data/lib/poptart/survey.rb +34 -7
- data/lib/poptart/survey_question.rb +32 -12
- data/lib/poptart/user.rb +4 -21
- data/lib/version.rb +1 -1
- data/poptart.gemspec +0 -4
- data/spec/lib/poptart/model_spec.rb +95 -0
- data/spec/lib/poptart/question_spec.rb +47 -0
- data/spec/lib/poptart/root_spec.rb +50 -0
- data/spec/lib/poptart/survey_question_spec.rb +166 -0
- data/spec/lib/poptart/survey_spec.rb +105 -0
- data/spec/lib/poptart/user_spec.rb +45 -0
- data/spec/requests/questions_spec.rb +31 -0
- data/spec/requests/survey_questions_spec.rb +150 -0
- data/spec/requests/surveys_spec.rb +34 -5
- data/spec/requests/{user_management_spec.rb → users_spec.rb} +5 -5
- data/spec/spec_helper.rb +1 -4
- data/spec/vcr/answering/survey_questions_answers_a_multiple_choice_question.yml +1527 -1596
- data/spec/vcr/answering/survey_questions_answers_a_survey_question.yml +2942 -2035
- data/spec/vcr/answering/survey_questions_creates_and_returns_a_random_question_survey.yml +254 -70
- data/spec/vcr/answering/survey_questions_creates_and_returns_an_empty_survey.yml +110 -48
- data/spec/vcr/answering/survey_questions_finds_survey_question_for_id.yml +1618 -286
- data/spec/vcr/poptart/survey/adds_a_question_to_a_survey.yml +1939 -0
- data/spec/vcr/poptart/survey/creates_a_random_survey.yml +318 -0
- data/spec/vcr/poptart/survey/creates_an_empty_survey.yml +702 -0
- data/spec/vcr/poptart/survey/returns_a_survey_by_id.yml +618 -0
- data/spec/vcr/poptart/user/creates_a_user.yml +179 -0
- data/spec/vcr/{user/management_creates_a_user.yml → poptart/user/returns_a_user.yml} +72 -69
- data/spec/vcr/questions/creates_a_question.yml +186 -0
- data/spec/vcr/questions/finds_a_question_by_id.yml +326 -0
- data/spec/vcr/questions/finds_a_question_by_key.yml +144 -0
- data/spec/vcr/questions/returns_all_answered_survey_questions_for_a_question.yml +1021 -0
- data/spec/vcr/retrieving/answers_returns_all_answered_survey_questions_for_a_question.yml +533 -479
- data/spec/vcr/survey/questions_answers_a_multiple_choice_question.yml +1454 -0
- data/spec/vcr/survey/questions_answers_a_survey_question.yml +1772 -0
- data/spec/vcr/survey/questions_creates_and_returns_an_empty_survey.yml +372 -0
- data/spec/vcr/survey/questions_finds_survey_question_for_id.yml +3083 -0
- data/spec/vcr/survey/questions_returns_all_answered_survey_questions_for_a_question.yml +5756 -0
- data/spec/vcr/survey/questions_returns_all_answered_survey_questions_for_a_question_by_key.yml +973 -0
- data/spec/vcr/survey/questions_returns_all_answered_survey_questions_for_a_survey.yml +620 -0
- metadata +55 -72
- data/lib/poptart/boolean_question.rb +0 -14
- data/lib/poptart/multiple_response_question.rb +0 -9
- data/lib/poptart/range_question.rb +0 -9
- data/lib/poptart/time_question.rb +0 -9
- data/spec/requests/answering_survey_questions_spec.rb +0 -79
- data/spec/requests/answers_spec.rb +0 -45
- data/spec/requests/creating_questions_spec.rb +0 -30
@@ -6757,85 +6757,6 @@ http_interactions:
|
|
6757
6757
|
}
|
6758
6758
|
http_version:
|
6759
6759
|
recorded_at: Mon, 13 Oct 2014 18:37:29 GMT
|
6760
|
-
- request:
|
6761
|
-
method: post
|
6762
|
-
uri: http://localhost:3000/api/surveys/56/survey_questions
|
6763
|
-
body:
|
6764
|
-
encoding: UTF-8
|
6765
|
-
string: '{"survey_question":{"question_id":68}}'
|
6766
|
-
headers:
|
6767
|
-
User-Agent:
|
6768
|
-
- Faraday v0.9.0
|
6769
|
-
Content-Type:
|
6770
|
-
- application/json
|
6771
|
-
Api-Token:
|
6772
|
-
- testing
|
6773
|
-
Accept-Encoding:
|
6774
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
6775
|
-
Accept:
|
6776
|
-
- "*/*"
|
6777
|
-
response:
|
6778
|
-
status:
|
6779
|
-
code: 201
|
6780
|
-
message: 'Created '
|
6781
|
-
headers:
|
6782
|
-
X-Frame-Options:
|
6783
|
-
- SAMEORIGIN
|
6784
|
-
X-Xss-Protection:
|
6785
|
-
- 1; mode=block
|
6786
|
-
X-Content-Type-Options:
|
6787
|
-
- nosniff
|
6788
|
-
X-Ua-Compatible:
|
6789
|
-
- chrome=1
|
6790
|
-
Content-Type:
|
6791
|
-
- application/json; charset=utf-8
|
6792
|
-
Etag:
|
6793
|
-
- '"4a0797f253933b18221af457ad8d3101"'
|
6794
|
-
Cache-Control:
|
6795
|
-
- max-age=0, private, must-revalidate
|
6796
|
-
X-Request-Id:
|
6797
|
-
- 311f67d8-16a8-41e0-a43e-0e0efe234e86
|
6798
|
-
X-Runtime:
|
6799
|
-
- '0.014300'
|
6800
|
-
Server:
|
6801
|
-
- WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
|
6802
|
-
Date:
|
6803
|
-
- Mon, 13 Oct 2014 18:37:29 GMT
|
6804
|
-
Content-Length:
|
6805
|
-
- '564'
|
6806
|
-
Connection:
|
6807
|
-
- Keep-Alive
|
6808
|
-
body:
|
6809
|
-
encoding: UTF-8
|
6810
|
-
string: |-
|
6811
|
-
{
|
6812
|
-
"id": 70,
|
6813
|
-
"text": "Do you like poptarts?",
|
6814
|
-
"type": "boolean",
|
6815
|
-
"responses": [
|
6816
|
-
"t",
|
6817
|
-
"f"
|
6818
|
-
],
|
6819
|
-
"answer": null,
|
6820
|
-
"freeform": false,
|
6821
|
-
"_links": {
|
6822
|
-
"self": {
|
6823
|
-
"href": "http://localhost:3000/api/surveys/56/survey_questions/70"
|
6824
|
-
},
|
6825
|
-
"post": {
|
6826
|
-
"href": "http://localhost:3000/api/surveys/56/survey_questions"
|
6827
|
-
},
|
6828
|
-
"put": {
|
6829
|
-
"href": "http://localhost:3000/api/surveys/56/survey_questions/70"
|
6830
|
-
},
|
6831
|
-
"survey": {
|
6832
|
-
"href": "http://localhost:3000/api/surveys/56"
|
6833
|
-
}
|
6834
|
-
},
|
6835
|
-
"created_at": "2014-10-13T18:37:29.967Z"
|
6836
|
-
}
|
6837
|
-
http_version:
|
6838
|
-
recorded_at: Mon, 13 Oct 2014 18:37:29 GMT
|
6839
6760
|
- request:
|
6840
6761
|
method: put
|
6841
6762
|
uri: http://localhost:3000/api/surveys/55/survey_questions/69
|
@@ -12357,82 +12278,6 @@ http_interactions:
|
|
12357
12278
|
}
|
12358
12279
|
http_version:
|
12359
12280
|
recorded_at: Sat, 18 Oct 2014 17:19:19 GMT
|
12360
|
-
- request:
|
12361
|
-
method: get
|
12362
|
-
uri: http://localhost:3000/
|
12363
|
-
body:
|
12364
|
-
encoding: US-ASCII
|
12365
|
-
string: ''
|
12366
|
-
headers:
|
12367
|
-
User-Agent:
|
12368
|
-
- Faraday v0.9.0
|
12369
|
-
Content-Type:
|
12370
|
-
- application/json
|
12371
|
-
Api-Token:
|
12372
|
-
- testing
|
12373
|
-
User-Token:
|
12374
|
-
- a14988474dc08067840960ca826b22f99d9c6e7211199525814f2348561a0631
|
12375
|
-
Service-User-Id:
|
12376
|
-
- b9131e60ab5f9665127a4995eef5e645d4532a0a171dc0e29dc6211a2ced6071
|
12377
|
-
Accept-Encoding:
|
12378
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
12379
|
-
Accept:
|
12380
|
-
- "*/*"
|
12381
|
-
response:
|
12382
|
-
status:
|
12383
|
-
code: 200
|
12384
|
-
message: 'OK '
|
12385
|
-
headers:
|
12386
|
-
X-Frame-Options:
|
12387
|
-
- SAMEORIGIN
|
12388
|
-
X-Xss-Protection:
|
12389
|
-
- 1; mode=block
|
12390
|
-
X-Content-Type-Options:
|
12391
|
-
- nosniff
|
12392
|
-
X-Ua-Compatible:
|
12393
|
-
- chrome=1
|
12394
|
-
Content-Type:
|
12395
|
-
- application/json; charset=utf-8
|
12396
|
-
Etag:
|
12397
|
-
- '"2aa11a1ab77b139e58f765299f923a01"'
|
12398
|
-
Cache-Control:
|
12399
|
-
- max-age=0, private, must-revalidate
|
12400
|
-
X-Request-Id:
|
12401
|
-
- f9a976fa-16d4-4136-bf67-25637839eacb
|
12402
|
-
X-Runtime:
|
12403
|
-
- '0.006423'
|
12404
|
-
Server:
|
12405
|
-
- WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
|
12406
|
-
Date:
|
12407
|
-
- Sat, 18 Oct 2014 17:26:54 GMT
|
12408
|
-
Content-Length:
|
12409
|
-
- '469'
|
12410
|
-
Connection:
|
12411
|
-
- Keep-Alive
|
12412
|
-
body:
|
12413
|
-
encoding: UTF-8
|
12414
|
-
string: |-
|
12415
|
-
{
|
12416
|
-
"_links": {
|
12417
|
-
"self": {
|
12418
|
-
"href": "http://localhost:3000/"
|
12419
|
-
},
|
12420
|
-
"surveys": {
|
12421
|
-
"href": "http://localhost:3000/api/surveys{/id}{?query*}"
|
12422
|
-
},
|
12423
|
-
"users": {
|
12424
|
-
"href": "http://localhost:3000/api/users{/id}{?query*}"
|
12425
|
-
},
|
12426
|
-
"questions": {
|
12427
|
-
"href": "http://localhost:3000/api/questions{/id}{?query*}"
|
12428
|
-
},
|
12429
|
-
"survey_questions": {
|
12430
|
-
"href": "http://localhost:3000/api/questions{/question_id}/survey_questions{?query*}"
|
12431
|
-
}
|
12432
|
-
}
|
12433
|
-
}
|
12434
|
-
http_version:
|
12435
|
-
recorded_at: Sat, 18 Oct 2014 17:26:54 GMT
|
12436
12281
|
- request:
|
12437
12282
|
method: post
|
12438
12283
|
uri: http://localhost:3000/api/surveys/130/survey_questions
|
@@ -12814,82 +12659,6 @@ http_interactions:
|
|
12814
12659
|
}
|
12815
12660
|
http_version:
|
12816
12661
|
recorded_at: Sat, 18 Oct 2014 17:26:54 GMT
|
12817
|
-
- request:
|
12818
|
-
method: get
|
12819
|
-
uri: http://localhost:3000/
|
12820
|
-
body:
|
12821
|
-
encoding: US-ASCII
|
12822
|
-
string: ''
|
12823
|
-
headers:
|
12824
|
-
User-Agent:
|
12825
|
-
- Faraday v0.9.0
|
12826
|
-
Content-Type:
|
12827
|
-
- application/json
|
12828
|
-
Api-Token:
|
12829
|
-
- testing
|
12830
|
-
User-Token:
|
12831
|
-
- 574e3b49fc1c33e93fb0ce689db1064c58dcd5c8f512b3732bd6d8fac32766ec
|
12832
|
-
Service-User-Id:
|
12833
|
-
- 4a4951740adbce9108586a6533faa2213137468d5fe965dfe72b708ef15ba9eb
|
12834
|
-
Accept-Encoding:
|
12835
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
12836
|
-
Accept:
|
12837
|
-
- "*/*"
|
12838
|
-
response:
|
12839
|
-
status:
|
12840
|
-
code: 200
|
12841
|
-
message: 'OK '
|
12842
|
-
headers:
|
12843
|
-
X-Frame-Options:
|
12844
|
-
- SAMEORIGIN
|
12845
|
-
X-Xss-Protection:
|
12846
|
-
- 1; mode=block
|
12847
|
-
X-Content-Type-Options:
|
12848
|
-
- nosniff
|
12849
|
-
X-Ua-Compatible:
|
12850
|
-
- chrome=1
|
12851
|
-
Content-Type:
|
12852
|
-
- application/json; charset=utf-8
|
12853
|
-
Etag:
|
12854
|
-
- '"2aa11a1ab77b139e58f765299f923a01"'
|
12855
|
-
Cache-Control:
|
12856
|
-
- max-age=0, private, must-revalidate
|
12857
|
-
X-Request-Id:
|
12858
|
-
- 6c35a2e2-5522-4036-9cba-76dab5768c39
|
12859
|
-
X-Runtime:
|
12860
|
-
- '0.007148'
|
12861
|
-
Server:
|
12862
|
-
- WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
|
12863
|
-
Date:
|
12864
|
-
- Sat, 18 Oct 2014 17:28:26 GMT
|
12865
|
-
Content-Length:
|
12866
|
-
- '469'
|
12867
|
-
Connection:
|
12868
|
-
- Keep-Alive
|
12869
|
-
body:
|
12870
|
-
encoding: UTF-8
|
12871
|
-
string: |-
|
12872
|
-
{
|
12873
|
-
"_links": {
|
12874
|
-
"self": {
|
12875
|
-
"href": "http://localhost:3000/"
|
12876
|
-
},
|
12877
|
-
"surveys": {
|
12878
|
-
"href": "http://localhost:3000/api/surveys{/id}{?query*}"
|
12879
|
-
},
|
12880
|
-
"users": {
|
12881
|
-
"href": "http://localhost:3000/api/users{/id}{?query*}"
|
12882
|
-
},
|
12883
|
-
"questions": {
|
12884
|
-
"href": "http://localhost:3000/api/questions{/id}{?query*}"
|
12885
|
-
},
|
12886
|
-
"survey_questions": {
|
12887
|
-
"href": "http://localhost:3000/api/questions{/question_id}/survey_questions{?query*}"
|
12888
|
-
}
|
12889
|
-
}
|
12890
|
-
}
|
12891
|
-
http_version:
|
12892
|
-
recorded_at: Sat, 18 Oct 2014 17:28:26 GMT
|
12893
12662
|
- request:
|
12894
12663
|
method: post
|
12895
12664
|
uri: http://localhost:3000/api/surveys/142/survey_questions
|
@@ -13272,11 +13041,11 @@ http_interactions:
|
|
13272
13041
|
http_version:
|
13273
13042
|
recorded_at: Sat, 18 Oct 2014 17:28:26 GMT
|
13274
13043
|
- request:
|
13275
|
-
method:
|
13276
|
-
uri: http://localhost:3000/
|
13044
|
+
method: post
|
13045
|
+
uri: http://localhost:3000/api/users
|
13277
13046
|
body:
|
13278
|
-
encoding:
|
13279
|
-
string:
|
13047
|
+
encoding: UTF-8
|
13048
|
+
string: "{}"
|
13280
13049
|
headers:
|
13281
13050
|
User-Agent:
|
13282
13051
|
- Faraday v0.9.0
|
@@ -13294,8 +13063,8 @@ http_interactions:
|
|
13294
13063
|
- "*/*"
|
13295
13064
|
response:
|
13296
13065
|
status:
|
13297
|
-
code:
|
13298
|
-
message: '
|
13066
|
+
code: 201
|
13067
|
+
message: 'Created '
|
13299
13068
|
headers:
|
13300
13069
|
X-Frame-Options:
|
13301
13070
|
- SAMEORIGIN
|
@@ -13308,52 +13077,41 @@ http_interactions:
|
|
13308
13077
|
Content-Type:
|
13309
13078
|
- application/json; charset=utf-8
|
13310
13079
|
Etag:
|
13311
|
-
- '"
|
13080
|
+
- '"2bacd76af83e69f2d3e53a5d2725d03d"'
|
13312
13081
|
Cache-Control:
|
13313
13082
|
- max-age=0, private, must-revalidate
|
13314
13083
|
X-Request-Id:
|
13315
|
-
-
|
13084
|
+
- 4959d720-ed89-4050-b174-6a8cabe4fcce
|
13316
13085
|
X-Runtime:
|
13317
|
-
- '0.
|
13086
|
+
- '0.007002'
|
13318
13087
|
Server:
|
13319
13088
|
- WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
|
13320
13089
|
Date:
|
13321
13090
|
- Sat, 18 Oct 2014 17:30:43 GMT
|
13322
13091
|
Content-Length:
|
13323
|
-
- '
|
13092
|
+
- '261'
|
13324
13093
|
Connection:
|
13325
13094
|
- Keep-Alive
|
13326
13095
|
body:
|
13327
13096
|
encoding: UTF-8
|
13328
13097
|
string: |-
|
13329
13098
|
{
|
13099
|
+
"service_user_id": "8104645e99aeda86d54dd596af7d3d91ed7909493bcf2e0e6291270d4303a471",
|
13330
13100
|
"_links": {
|
13331
13101
|
"self": {
|
13332
|
-
"href": "http://localhost:3000/"
|
13333
|
-
},
|
13334
|
-
"surveys": {
|
13335
|
-
"href": "http://localhost:3000/api/surveys{/id}{?query*}"
|
13336
|
-
},
|
13337
|
-
"users": {
|
13338
|
-
"href": "http://localhost:3000/api/users{/id}{?query*}"
|
13339
|
-
},
|
13340
|
-
"questions": {
|
13341
|
-
"href": "http://localhost:3000/api/questions{/id}{?query*}"
|
13342
|
-
},
|
13343
|
-
"survey_questions": {
|
13344
|
-
"href": "http://localhost:3000/api/questions{/question_id}/survey_questions{?query*}"
|
13102
|
+
"href": "http://localhost:3000/api/users/149"
|
13345
13103
|
}
|
13346
|
-
}
|
13104
|
+
},
|
13105
|
+
"token": "cd13490902b4944acf6af4d6e8505c8e44b68e841dbfca133523f68b941587b7"
|
13347
13106
|
}
|
13348
13107
|
http_version:
|
13349
13108
|
recorded_at: Sat, 18 Oct 2014 17:30:43 GMT
|
13350
13109
|
- request:
|
13351
13110
|
method: post
|
13352
|
-
uri: http://localhost:3000/api/
|
13111
|
+
uri: http://localhost:3000/api/surveys/184/survey_questions
|
13353
13112
|
body:
|
13354
13113
|
encoding: UTF-8
|
13355
|
-
string: '{"
|
13356
|
-
you like poptarts?","freeform":false,"absolute_index":null,"parent_question_id":null,"key":null}}'
|
13114
|
+
string: '{"survey_question":{"question_id":125}}'
|
13357
13115
|
headers:
|
13358
13116
|
User-Agent:
|
13359
13117
|
- Faraday v0.9.0
|
@@ -13385,242 +13143,28 @@ http_interactions:
|
|
13385
13143
|
Content-Type:
|
13386
13144
|
- application/json; charset=utf-8
|
13387
13145
|
Etag:
|
13388
|
-
- '"
|
13146
|
+
- '"8b81ecc5f216a65268023e82995da449"'
|
13389
13147
|
Cache-Control:
|
13390
13148
|
- max-age=0, private, must-revalidate
|
13391
13149
|
X-Request-Id:
|
13392
|
-
-
|
13150
|
+
- d6a8c43b-ff16-4486-93f5-5cbd33179795
|
13393
13151
|
X-Runtime:
|
13394
|
-
- '0.
|
13152
|
+
- '0.013210'
|
13395
13153
|
Server:
|
13396
13154
|
- WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
|
13397
13155
|
Date:
|
13398
13156
|
- Sat, 18 Oct 2014 17:30:43 GMT
|
13399
13157
|
Content-Length:
|
13400
|
-
- '
|
13158
|
+
- '571'
|
13401
13159
|
Connection:
|
13402
13160
|
- Keep-Alive
|
13403
13161
|
body:
|
13404
13162
|
encoding: UTF-8
|
13405
13163
|
string: |-
|
13406
13164
|
{
|
13407
|
-
"id":
|
13408
|
-
"question_type": "boolean",
|
13165
|
+
"id": 267,
|
13409
13166
|
"text": "Do you like poptarts?",
|
13410
|
-
"
|
13411
|
-
true,
|
13412
|
-
false
|
13413
|
-
],
|
13414
|
-
"freeform": false,
|
13415
|
-
"absolute_index": null,
|
13416
|
-
"parent_question_id": null,
|
13417
|
-
"key": null
|
13418
|
-
}
|
13419
|
-
http_version:
|
13420
|
-
recorded_at: Sat, 18 Oct 2014 17:30:43 GMT
|
13421
|
-
- request:
|
13422
|
-
method: post
|
13423
|
-
uri: http://localhost:3000/api/users
|
13424
|
-
body:
|
13425
|
-
encoding: UTF-8
|
13426
|
-
string: "{}"
|
13427
|
-
headers:
|
13428
|
-
User-Agent:
|
13429
|
-
- Faraday v0.9.0
|
13430
|
-
Content-Type:
|
13431
|
-
- application/json
|
13432
|
-
Api-Token:
|
13433
|
-
- testing
|
13434
|
-
User-Token:
|
13435
|
-
- cd13490902b4944acf6af4d6e8505c8e44b68e841dbfca133523f68b941587b7
|
13436
|
-
Service-User-Id:
|
13437
|
-
- 8104645e99aeda86d54dd596af7d3d91ed7909493bcf2e0e6291270d4303a471
|
13438
|
-
Accept-Encoding:
|
13439
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
13440
|
-
Accept:
|
13441
|
-
- "*/*"
|
13442
|
-
response:
|
13443
|
-
status:
|
13444
|
-
code: 201
|
13445
|
-
message: 'Created '
|
13446
|
-
headers:
|
13447
|
-
X-Frame-Options:
|
13448
|
-
- SAMEORIGIN
|
13449
|
-
X-Xss-Protection:
|
13450
|
-
- 1; mode=block
|
13451
|
-
X-Content-Type-Options:
|
13452
|
-
- nosniff
|
13453
|
-
X-Ua-Compatible:
|
13454
|
-
- chrome=1
|
13455
|
-
Content-Type:
|
13456
|
-
- application/json; charset=utf-8
|
13457
|
-
Etag:
|
13458
|
-
- '"2bacd76af83e69f2d3e53a5d2725d03d"'
|
13459
|
-
Cache-Control:
|
13460
|
-
- max-age=0, private, must-revalidate
|
13461
|
-
X-Request-Id:
|
13462
|
-
- 4959d720-ed89-4050-b174-6a8cabe4fcce
|
13463
|
-
X-Runtime:
|
13464
|
-
- '0.007002'
|
13465
|
-
Server:
|
13466
|
-
- WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
|
13467
|
-
Date:
|
13468
|
-
- Sat, 18 Oct 2014 17:30:43 GMT
|
13469
|
-
Content-Length:
|
13470
|
-
- '261'
|
13471
|
-
Connection:
|
13472
|
-
- Keep-Alive
|
13473
|
-
body:
|
13474
|
-
encoding: UTF-8
|
13475
|
-
string: |-
|
13476
|
-
{
|
13477
|
-
"service_user_id": "8104645e99aeda86d54dd596af7d3d91ed7909493bcf2e0e6291270d4303a471",
|
13478
|
-
"_links": {
|
13479
|
-
"self": {
|
13480
|
-
"href": "http://localhost:3000/api/users/149"
|
13481
|
-
}
|
13482
|
-
},
|
13483
|
-
"token": "cd13490902b4944acf6af4d6e8505c8e44b68e841dbfca133523f68b941587b7"
|
13484
|
-
}
|
13485
|
-
http_version:
|
13486
|
-
recorded_at: Sat, 18 Oct 2014 17:30:43 GMT
|
13487
|
-
- request:
|
13488
|
-
method: post
|
13489
|
-
uri: http://localhost:3000/api/surveys
|
13490
|
-
body:
|
13491
|
-
encoding: UTF-8
|
13492
|
-
string: '{"survey":{"service_user_id":"8104645e99aeda86d54dd596af7d3d91ed7909493bcf2e0e6291270d4303a471"}}'
|
13493
|
-
headers:
|
13494
|
-
User-Agent:
|
13495
|
-
- Faraday v0.9.0
|
13496
|
-
Content-Type:
|
13497
|
-
- application/json
|
13498
|
-
Api-Token:
|
13499
|
-
- testing
|
13500
|
-
User-Token:
|
13501
|
-
- cd13490902b4944acf6af4d6e8505c8e44b68e841dbfca133523f68b941587b7
|
13502
|
-
Service-User-Id:
|
13503
|
-
- 8104645e99aeda86d54dd596af7d3d91ed7909493bcf2e0e6291270d4303a471
|
13504
|
-
Accept-Encoding:
|
13505
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
13506
|
-
Accept:
|
13507
|
-
- "*/*"
|
13508
|
-
response:
|
13509
|
-
status:
|
13510
|
-
code: 201
|
13511
|
-
message: 'Created '
|
13512
|
-
headers:
|
13513
|
-
X-Frame-Options:
|
13514
|
-
- SAMEORIGIN
|
13515
|
-
X-Xss-Protection:
|
13516
|
-
- 1; mode=block
|
13517
|
-
X-Content-Type-Options:
|
13518
|
-
- nosniff
|
13519
|
-
X-Ua-Compatible:
|
13520
|
-
- chrome=1
|
13521
|
-
Content-Type:
|
13522
|
-
- application/json; charset=utf-8
|
13523
|
-
Etag:
|
13524
|
-
- '"ca317e6f2765cba8dc3e1695cfb61b32"'
|
13525
|
-
Cache-Control:
|
13526
|
-
- max-age=0, private, must-revalidate
|
13527
|
-
X-Request-Id:
|
13528
|
-
- 2818bebf-e222-4ab1-a6a1-b88d24096874
|
13529
|
-
X-Runtime:
|
13530
|
-
- '0.020944'
|
13531
|
-
Server:
|
13532
|
-
- WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
|
13533
|
-
Date:
|
13534
|
-
- Sat, 18 Oct 2014 17:30:43 GMT
|
13535
|
-
Content-Length:
|
13536
|
-
- '476'
|
13537
|
-
Connection:
|
13538
|
-
- Keep-Alive
|
13539
|
-
body:
|
13540
|
-
encoding: UTF-8
|
13541
|
-
string: |-
|
13542
|
-
{
|
13543
|
-
"id": 184,
|
13544
|
-
"service_user_id": "8104645e99aeda86d54dd596af7d3d91ed7909493bcf2e0e6291270d4303a471",
|
13545
|
-
"_links": {
|
13546
|
-
"self": {
|
13547
|
-
"href": "http://localhost:3000/api/surveys/184"
|
13548
|
-
},
|
13549
|
-
"survey_questions": {
|
13550
|
-
"post": {
|
13551
|
-
"href": "http://localhost:3000/api/surveys/184/survey_questions"
|
13552
|
-
},
|
13553
|
-
"put": {
|
13554
|
-
"href": "http://localhost:3000/api/surveys/184/survey_questions"
|
13555
|
-
}
|
13556
|
-
}
|
13557
|
-
},
|
13558
|
-
"completed": false,
|
13559
|
-
"survey_questions": [
|
13560
|
-
|
13561
|
-
]
|
13562
|
-
}
|
13563
|
-
http_version:
|
13564
|
-
recorded_at: Sat, 18 Oct 2014 17:30:43 GMT
|
13565
|
-
- request:
|
13566
|
-
method: post
|
13567
|
-
uri: http://localhost:3000/api/surveys/184/survey_questions
|
13568
|
-
body:
|
13569
|
-
encoding: UTF-8
|
13570
|
-
string: '{"survey_question":{"question_id":125}}'
|
13571
|
-
headers:
|
13572
|
-
User-Agent:
|
13573
|
-
- Faraday v0.9.0
|
13574
|
-
Content-Type:
|
13575
|
-
- application/json
|
13576
|
-
Api-Token:
|
13577
|
-
- testing
|
13578
|
-
User-Token:
|
13579
|
-
- cd13490902b4944acf6af4d6e8505c8e44b68e841dbfca133523f68b941587b7
|
13580
|
-
Service-User-Id:
|
13581
|
-
- 8104645e99aeda86d54dd596af7d3d91ed7909493bcf2e0e6291270d4303a471
|
13582
|
-
Accept-Encoding:
|
13583
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
13584
|
-
Accept:
|
13585
|
-
- "*/*"
|
13586
|
-
response:
|
13587
|
-
status:
|
13588
|
-
code: 201
|
13589
|
-
message: 'Created '
|
13590
|
-
headers:
|
13591
|
-
X-Frame-Options:
|
13592
|
-
- SAMEORIGIN
|
13593
|
-
X-Xss-Protection:
|
13594
|
-
- 1; mode=block
|
13595
|
-
X-Content-Type-Options:
|
13596
|
-
- nosniff
|
13597
|
-
X-Ua-Compatible:
|
13598
|
-
- chrome=1
|
13599
|
-
Content-Type:
|
13600
|
-
- application/json; charset=utf-8
|
13601
|
-
Etag:
|
13602
|
-
- '"8b81ecc5f216a65268023e82995da449"'
|
13603
|
-
Cache-Control:
|
13604
|
-
- max-age=0, private, must-revalidate
|
13605
|
-
X-Request-Id:
|
13606
|
-
- d6a8c43b-ff16-4486-93f5-5cbd33179795
|
13607
|
-
X-Runtime:
|
13608
|
-
- '0.013210'
|
13609
|
-
Server:
|
13610
|
-
- WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
|
13611
|
-
Date:
|
13612
|
-
- Sat, 18 Oct 2014 17:30:43 GMT
|
13613
|
-
Content-Length:
|
13614
|
-
- '571'
|
13615
|
-
Connection:
|
13616
|
-
- Keep-Alive
|
13617
|
-
body:
|
13618
|
-
encoding: UTF-8
|
13619
|
-
string: |-
|
13620
|
-
{
|
13621
|
-
"id": 267,
|
13622
|
-
"text": "Do you like poptarts?",
|
13623
|
-
"type": "boolean",
|
13167
|
+
"type": "boolean",
|
13624
13168
|
"responses": [
|
13625
13169
|
"t",
|
13626
13170
|
"f"
|
@@ -14021,4 +13565,514 @@ http_interactions:
|
|
14021
13565
|
}
|
14022
13566
|
http_version:
|
14023
13567
|
recorded_at: Sat, 18 Oct 2014 17:30:44 GMT
|
14024
|
-
|
13568
|
+
- request:
|
13569
|
+
method: get
|
13570
|
+
uri: http://localhost:3000/
|
13571
|
+
body:
|
13572
|
+
encoding: US-ASCII
|
13573
|
+
string: ''
|
13574
|
+
headers:
|
13575
|
+
User-Agent:
|
13576
|
+
- Faraday v0.9.0
|
13577
|
+
Content-Type:
|
13578
|
+
- application/json
|
13579
|
+
Api-Token:
|
13580
|
+
- testing
|
13581
|
+
Accept-Encoding:
|
13582
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
13583
|
+
Accept:
|
13584
|
+
- "*/*"
|
13585
|
+
response:
|
13586
|
+
status:
|
13587
|
+
code: 200
|
13588
|
+
message: 'OK '
|
13589
|
+
headers:
|
13590
|
+
X-Frame-Options:
|
13591
|
+
- SAMEORIGIN
|
13592
|
+
X-Xss-Protection:
|
13593
|
+
- 1; mode=block
|
13594
|
+
X-Content-Type-Options:
|
13595
|
+
- nosniff
|
13596
|
+
X-Ua-Compatible:
|
13597
|
+
- chrome=1
|
13598
|
+
Content-Type:
|
13599
|
+
- application/json; charset=utf-8
|
13600
|
+
Etag:
|
13601
|
+
- '"cd727c0ba392005a102fbf8dc32be000"'
|
13602
|
+
Cache-Control:
|
13603
|
+
- max-age=0, private, must-revalidate
|
13604
|
+
X-Request-Id:
|
13605
|
+
- ccb4d321-24de-4efd-84f1-0fa2492d82e9
|
13606
|
+
X-Runtime:
|
13607
|
+
- '0.009956'
|
13608
|
+
Server:
|
13609
|
+
- WEBrick/1.3.1 (Ruby/2.1.3/2014-09-19)
|
13610
|
+
Date:
|
13611
|
+
- Sat, 17 Jan 2015 14:15:00 GMT
|
13612
|
+
Content-Length:
|
13613
|
+
- '479'
|
13614
|
+
Connection:
|
13615
|
+
- Keep-Alive
|
13616
|
+
body:
|
13617
|
+
encoding: UTF-8
|
13618
|
+
string: |-
|
13619
|
+
{
|
13620
|
+
"_links": {
|
13621
|
+
"self": {
|
13622
|
+
"href": "http://localhost:3000/"
|
13623
|
+
},
|
13624
|
+
"surveys": {
|
13625
|
+
"href": "http://localhost:3000/api/surveys{/id}{?query*}"
|
13626
|
+
},
|
13627
|
+
"users": {
|
13628
|
+
"href": "http://localhost:3000/api/user{/id}{?query*}"
|
13629
|
+
},
|
13630
|
+
"questions": {
|
13631
|
+
"href": "http://localhost:3000/api/questions{/id}{?query*}"
|
13632
|
+
},
|
13633
|
+
"survey_questions": {
|
13634
|
+
"href": "http://localhost:3000/api/questions/surveys/{survey_id}/survey_questions{/id}{?query*}"
|
13635
|
+
}
|
13636
|
+
}
|
13637
|
+
}
|
13638
|
+
http_version:
|
13639
|
+
recorded_at: Sat, 17 Jan 2015 14:15:00 GMT
|
13640
|
+
- request:
|
13641
|
+
method: post
|
13642
|
+
uri: http://localhost:3000/api/questions
|
13643
|
+
body:
|
13644
|
+
encoding: UTF-8
|
13645
|
+
string: '{"question":{"question_type":"boolean","responses":[true,false],"text":"Do
|
13646
|
+
you like poptarts?","key":null}}'
|
13647
|
+
headers:
|
13648
|
+
User-Agent:
|
13649
|
+
- Faraday v0.9.0
|
13650
|
+
Content-Type:
|
13651
|
+
- application/json
|
13652
|
+
Api-Token:
|
13653
|
+
- testing
|
13654
|
+
Accept-Encoding:
|
13655
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
13656
|
+
Accept:
|
13657
|
+
- "*/*"
|
13658
|
+
response:
|
13659
|
+
status:
|
13660
|
+
code: 201
|
13661
|
+
message: 'Created '
|
13662
|
+
headers:
|
13663
|
+
X-Frame-Options:
|
13664
|
+
- SAMEORIGIN
|
13665
|
+
X-Xss-Protection:
|
13666
|
+
- 1; mode=block
|
13667
|
+
X-Content-Type-Options:
|
13668
|
+
- nosniff
|
13669
|
+
X-Ua-Compatible:
|
13670
|
+
- chrome=1
|
13671
|
+
Content-Type:
|
13672
|
+
- application/json; charset=utf-8
|
13673
|
+
Etag:
|
13674
|
+
- '"0d31f0b7c85ce09009cee2f699f7406b"'
|
13675
|
+
Cache-Control:
|
13676
|
+
- max-age=0, private, must-revalidate
|
13677
|
+
X-Request-Id:
|
13678
|
+
- b658b987-d09f-4825-bb29-1895b3802926
|
13679
|
+
X-Runtime:
|
13680
|
+
- '0.009564'
|
13681
|
+
Server:
|
13682
|
+
- WEBrick/1.3.1 (Ruby/2.1.3/2014-09-19)
|
13683
|
+
Date:
|
13684
|
+
- Sat, 17 Jan 2015 14:15:00 GMT
|
13685
|
+
Content-Length:
|
13686
|
+
- '230'
|
13687
|
+
Connection:
|
13688
|
+
- Keep-Alive
|
13689
|
+
body:
|
13690
|
+
encoding: UTF-8
|
13691
|
+
string: |-
|
13692
|
+
{
|
13693
|
+
"id": 63,
|
13694
|
+
"question_type": "boolean",
|
13695
|
+
"text": "Do you like poptarts?",
|
13696
|
+
"responses": [
|
13697
|
+
true,
|
13698
|
+
false
|
13699
|
+
],
|
13700
|
+
"key": null,
|
13701
|
+
"_links": {
|
13702
|
+
"self": {
|
13703
|
+
"href": "http://localhost:3000/api/questions/63"
|
13704
|
+
}
|
13705
|
+
}
|
13706
|
+
}
|
13707
|
+
http_version:
|
13708
|
+
recorded_at: Sat, 17 Jan 2015 14:15:00 GMT
|
13709
|
+
- request:
|
13710
|
+
method: get
|
13711
|
+
uri: http://localhost:3000/
|
13712
|
+
body:
|
13713
|
+
encoding: US-ASCII
|
13714
|
+
string: ''
|
13715
|
+
headers:
|
13716
|
+
User-Agent:
|
13717
|
+
- Faraday v0.9.0
|
13718
|
+
Content-Type:
|
13719
|
+
- application/json
|
13720
|
+
Api-Token:
|
13721
|
+
- testing
|
13722
|
+
Accept-Encoding:
|
13723
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
13724
|
+
Accept:
|
13725
|
+
- "*/*"
|
13726
|
+
response:
|
13727
|
+
status:
|
13728
|
+
code: 200
|
13729
|
+
message: 'OK '
|
13730
|
+
headers:
|
13731
|
+
X-Frame-Options:
|
13732
|
+
- SAMEORIGIN
|
13733
|
+
X-Xss-Protection:
|
13734
|
+
- 1; mode=block
|
13735
|
+
X-Content-Type-Options:
|
13736
|
+
- nosniff
|
13737
|
+
X-Ua-Compatible:
|
13738
|
+
- chrome=1
|
13739
|
+
Content-Type:
|
13740
|
+
- application/json; charset=utf-8
|
13741
|
+
Etag:
|
13742
|
+
- '"cd727c0ba392005a102fbf8dc32be000"'
|
13743
|
+
Cache-Control:
|
13744
|
+
- max-age=0, private, must-revalidate
|
13745
|
+
X-Request-Id:
|
13746
|
+
- 35e23a78-a600-4814-978e-58cbbf1cc8f4
|
13747
|
+
X-Runtime:
|
13748
|
+
- '0.006806'
|
13749
|
+
Server:
|
13750
|
+
- WEBrick/1.3.1 (Ruby/2.1.3/2014-09-19)
|
13751
|
+
Date:
|
13752
|
+
- Sat, 17 Jan 2015 14:15:00 GMT
|
13753
|
+
Content-Length:
|
13754
|
+
- '479'
|
13755
|
+
Connection:
|
13756
|
+
- Keep-Alive
|
13757
|
+
body:
|
13758
|
+
encoding: UTF-8
|
13759
|
+
string: |-
|
13760
|
+
{
|
13761
|
+
"_links": {
|
13762
|
+
"self": {
|
13763
|
+
"href": "http://localhost:3000/"
|
13764
|
+
},
|
13765
|
+
"surveys": {
|
13766
|
+
"href": "http://localhost:3000/api/surveys{/id}{?query*}"
|
13767
|
+
},
|
13768
|
+
"users": {
|
13769
|
+
"href": "http://localhost:3000/api/user{/id}{?query*}"
|
13770
|
+
},
|
13771
|
+
"questions": {
|
13772
|
+
"href": "http://localhost:3000/api/questions{/id}{?query*}"
|
13773
|
+
},
|
13774
|
+
"survey_questions": {
|
13775
|
+
"href": "http://localhost:3000/api/questions/surveys/{survey_id}/survey_questions{/id}{?query*}"
|
13776
|
+
}
|
13777
|
+
}
|
13778
|
+
}
|
13779
|
+
http_version:
|
13780
|
+
recorded_at: Sat, 17 Jan 2015 14:15:00 GMT
|
13781
|
+
- request:
|
13782
|
+
method: post
|
13783
|
+
uri: http://localhost:3000/api/user
|
13784
|
+
body:
|
13785
|
+
encoding: UTF-8
|
13786
|
+
string: "{}"
|
13787
|
+
headers:
|
13788
|
+
User-Agent:
|
13789
|
+
- Faraday v0.9.0
|
13790
|
+
Content-Type:
|
13791
|
+
- application/json
|
13792
|
+
Api-Token:
|
13793
|
+
- testing
|
13794
|
+
Accept-Encoding:
|
13795
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
13796
|
+
Accept:
|
13797
|
+
- "*/*"
|
13798
|
+
response:
|
13799
|
+
status:
|
13800
|
+
code: 201
|
13801
|
+
message: 'Created '
|
13802
|
+
headers:
|
13803
|
+
X-Frame-Options:
|
13804
|
+
- SAMEORIGIN
|
13805
|
+
X-Xss-Protection:
|
13806
|
+
- 1; mode=block
|
13807
|
+
X-Content-Type-Options:
|
13808
|
+
- nosniff
|
13809
|
+
X-Ua-Compatible:
|
13810
|
+
- chrome=1
|
13811
|
+
Content-Type:
|
13812
|
+
- application/json; charset=utf-8
|
13813
|
+
Etag:
|
13814
|
+
- '"5a7a8e2a1f69756335e9168a4f5fdda2"'
|
13815
|
+
Cache-Control:
|
13816
|
+
- max-age=0, private, must-revalidate
|
13817
|
+
X-Request-Id:
|
13818
|
+
- 9ee1af22-fa78-4627-b311-6fb09bafed32
|
13819
|
+
X-Runtime:
|
13820
|
+
- '0.008153'
|
13821
|
+
Server:
|
13822
|
+
- WEBrick/1.3.1 (Ruby/2.1.3/2014-09-19)
|
13823
|
+
Date:
|
13824
|
+
- Sat, 17 Jan 2015 14:15:00 GMT
|
13825
|
+
Content-Length:
|
13826
|
+
- '256'
|
13827
|
+
Connection:
|
13828
|
+
- Keep-Alive
|
13829
|
+
body:
|
13830
|
+
encoding: UTF-8
|
13831
|
+
string: |-
|
13832
|
+
{
|
13833
|
+
"service_user_id": "533dfa45ec729286c18518e8bbe98cd847a73870da99e7a54eb76bd75a2ea3df",
|
13834
|
+
"_links": {
|
13835
|
+
"self": {
|
13836
|
+
"href": "http://localhost:3000/api/user"
|
13837
|
+
}
|
13838
|
+
},
|
13839
|
+
"token": "0374c39519b0bdc143e3e9cf9392b59138b26f16523d6010fab1ebea2e7c546d"
|
13840
|
+
}
|
13841
|
+
http_version:
|
13842
|
+
recorded_at: Sat, 17 Jan 2015 14:15:00 GMT
|
13843
|
+
- request:
|
13844
|
+
method: get
|
13845
|
+
uri: http://localhost:3000/
|
13846
|
+
body:
|
13847
|
+
encoding: US-ASCII
|
13848
|
+
string: ''
|
13849
|
+
headers:
|
13850
|
+
User-Agent:
|
13851
|
+
- Faraday v0.9.0
|
13852
|
+
Content-Type:
|
13853
|
+
- application/json
|
13854
|
+
Api-Token:
|
13855
|
+
- testing
|
13856
|
+
User-Token:
|
13857
|
+
- 0374c39519b0bdc143e3e9cf9392b59138b26f16523d6010fab1ebea2e7c546d
|
13858
|
+
Service-User-Id:
|
13859
|
+
- 533dfa45ec729286c18518e8bbe98cd847a73870da99e7a54eb76bd75a2ea3df
|
13860
|
+
Accept-Encoding:
|
13861
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
13862
|
+
Accept:
|
13863
|
+
- "*/*"
|
13864
|
+
response:
|
13865
|
+
status:
|
13866
|
+
code: 200
|
13867
|
+
message: 'OK '
|
13868
|
+
headers:
|
13869
|
+
X-Frame-Options:
|
13870
|
+
- SAMEORIGIN
|
13871
|
+
X-Xss-Protection:
|
13872
|
+
- 1; mode=block
|
13873
|
+
X-Content-Type-Options:
|
13874
|
+
- nosniff
|
13875
|
+
X-Ua-Compatible:
|
13876
|
+
- chrome=1
|
13877
|
+
Content-Type:
|
13878
|
+
- application/json; charset=utf-8
|
13879
|
+
Etag:
|
13880
|
+
- '"cd727c0ba392005a102fbf8dc32be000"'
|
13881
|
+
Cache-Control:
|
13882
|
+
- max-age=0, private, must-revalidate
|
13883
|
+
X-Request-Id:
|
13884
|
+
- b5439541-9ffe-4cbc-8f1d-d56fb7435874
|
13885
|
+
X-Runtime:
|
13886
|
+
- '0.005704'
|
13887
|
+
Server:
|
13888
|
+
- WEBrick/1.3.1 (Ruby/2.1.3/2014-09-19)
|
13889
|
+
Date:
|
13890
|
+
- Sat, 17 Jan 2015 14:15:00 GMT
|
13891
|
+
Content-Length:
|
13892
|
+
- '479'
|
13893
|
+
Connection:
|
13894
|
+
- Keep-Alive
|
13895
|
+
body:
|
13896
|
+
encoding: UTF-8
|
13897
|
+
string: |-
|
13898
|
+
{
|
13899
|
+
"_links": {
|
13900
|
+
"self": {
|
13901
|
+
"href": "http://localhost:3000/"
|
13902
|
+
},
|
13903
|
+
"surveys": {
|
13904
|
+
"href": "http://localhost:3000/api/surveys{/id}{?query*}"
|
13905
|
+
},
|
13906
|
+
"users": {
|
13907
|
+
"href": "http://localhost:3000/api/user{/id}{?query*}"
|
13908
|
+
},
|
13909
|
+
"questions": {
|
13910
|
+
"href": "http://localhost:3000/api/questions{/id}{?query*}"
|
13911
|
+
},
|
13912
|
+
"survey_questions": {
|
13913
|
+
"href": "http://localhost:3000/api/questions/surveys/{survey_id}/survey_questions{/id}{?query*}"
|
13914
|
+
}
|
13915
|
+
}
|
13916
|
+
}
|
13917
|
+
http_version:
|
13918
|
+
recorded_at: Sat, 17 Jan 2015 14:15:00 GMT
|
13919
|
+
- request:
|
13920
|
+
method: post
|
13921
|
+
uri: http://localhost:3000/api/surveys
|
13922
|
+
body:
|
13923
|
+
encoding: UTF-8
|
13924
|
+
string: "{}"
|
13925
|
+
headers:
|
13926
|
+
User-Agent:
|
13927
|
+
- Faraday v0.9.0
|
13928
|
+
Content-Type:
|
13929
|
+
- application/json
|
13930
|
+
Api-Token:
|
13931
|
+
- testing
|
13932
|
+
User-Token:
|
13933
|
+
- 0374c39519b0bdc143e3e9cf9392b59138b26f16523d6010fab1ebea2e7c546d
|
13934
|
+
Service-User-Id:
|
13935
|
+
- 533dfa45ec729286c18518e8bbe98cd847a73870da99e7a54eb76bd75a2ea3df
|
13936
|
+
Accept-Encoding:
|
13937
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
13938
|
+
Accept:
|
13939
|
+
- "*/*"
|
13940
|
+
response:
|
13941
|
+
status:
|
13942
|
+
code: 201
|
13943
|
+
message: 'Created '
|
13944
|
+
headers:
|
13945
|
+
X-Frame-Options:
|
13946
|
+
- SAMEORIGIN
|
13947
|
+
X-Xss-Protection:
|
13948
|
+
- 1; mode=block
|
13949
|
+
X-Content-Type-Options:
|
13950
|
+
- nosniff
|
13951
|
+
X-Ua-Compatible:
|
13952
|
+
- chrome=1
|
13953
|
+
Content-Type:
|
13954
|
+
- application/json; charset=utf-8
|
13955
|
+
Etag:
|
13956
|
+
- '"390c84233159cd34e891a74fba425b04"'
|
13957
|
+
Cache-Control:
|
13958
|
+
- max-age=0, private, must-revalidate
|
13959
|
+
X-Request-Id:
|
13960
|
+
- e5164929-154e-4e07-9754-864b490cffa4
|
13961
|
+
X-Runtime:
|
13962
|
+
- '0.033419'
|
13963
|
+
Server:
|
13964
|
+
- WEBrick/1.3.1 (Ruby/2.1.3/2014-09-19)
|
13965
|
+
Date:
|
13966
|
+
- Sat, 17 Jan 2015 14:15:00 GMT
|
13967
|
+
Content-Length:
|
13968
|
+
- '471'
|
13969
|
+
Connection:
|
13970
|
+
- Keep-Alive
|
13971
|
+
body:
|
13972
|
+
encoding: UTF-8
|
13973
|
+
string: |-
|
13974
|
+
{
|
13975
|
+
"id": 56,
|
13976
|
+
"service_user_id": "533dfa45ec729286c18518e8bbe98cd847a73870da99e7a54eb76bd75a2ea3df",
|
13977
|
+
"_links": {
|
13978
|
+
"self": {
|
13979
|
+
"href": "http://localhost:3000/api/surveys/56"
|
13980
|
+
},
|
13981
|
+
"survey_questions": {
|
13982
|
+
"post": {
|
13983
|
+
"href": "http://localhost:3000/api/surveys/56/survey_questions"
|
13984
|
+
},
|
13985
|
+
"put": {
|
13986
|
+
"href": "http://localhost:3000/api/surveys/56/survey_questions"
|
13987
|
+
}
|
13988
|
+
}
|
13989
|
+
},
|
13990
|
+
"completed": true,
|
13991
|
+
"survey_questions": [
|
13992
|
+
|
13993
|
+
]
|
13994
|
+
}
|
13995
|
+
http_version:
|
13996
|
+
recorded_at: Sat, 17 Jan 2015 14:15:00 GMT
|
13997
|
+
- request:
|
13998
|
+
method: post
|
13999
|
+
uri: http://localhost:3000/api/surveys/56/survey_questions
|
14000
|
+
body:
|
14001
|
+
encoding: UTF-8
|
14002
|
+
string: '{"survey_question":{"question_id":63,"responses":null}}'
|
14003
|
+
headers:
|
14004
|
+
User-Agent:
|
14005
|
+
- Faraday v0.9.0
|
14006
|
+
Content-Type:
|
14007
|
+
- application/json
|
14008
|
+
Api-Token:
|
14009
|
+
- testing
|
14010
|
+
User-Token:
|
14011
|
+
- 0374c39519b0bdc143e3e9cf9392b59138b26f16523d6010fab1ebea2e7c546d
|
14012
|
+
Service-User-Id:
|
14013
|
+
- 533dfa45ec729286c18518e8bbe98cd847a73870da99e7a54eb76bd75a2ea3df
|
14014
|
+
Accept-Encoding:
|
14015
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
14016
|
+
Accept:
|
14017
|
+
- "*/*"
|
14018
|
+
response:
|
14019
|
+
status:
|
14020
|
+
code: 201
|
14021
|
+
message: 'Created '
|
14022
|
+
headers:
|
14023
|
+
X-Frame-Options:
|
14024
|
+
- SAMEORIGIN
|
14025
|
+
X-Xss-Protection:
|
14026
|
+
- 1; mode=block
|
14027
|
+
X-Content-Type-Options:
|
14028
|
+
- nosniff
|
14029
|
+
X-Ua-Compatible:
|
14030
|
+
- chrome=1
|
14031
|
+
Content-Type:
|
14032
|
+
- application/json; charset=utf-8
|
14033
|
+
Etag:
|
14034
|
+
- '"c9463a0a39dbd6d8394f29b449f56fd2"'
|
14035
|
+
Cache-Control:
|
14036
|
+
- max-age=0, private, must-revalidate
|
14037
|
+
X-Request-Id:
|
14038
|
+
- 48262a08-bb3c-437d-af7a-f1b08184eed6
|
14039
|
+
X-Runtime:
|
14040
|
+
- '0.019446'
|
14041
|
+
Server:
|
14042
|
+
- WEBrick/1.3.1 (Ruby/2.1.3/2014-09-19)
|
14043
|
+
Date:
|
14044
|
+
- Sat, 17 Jan 2015 14:15:00 GMT
|
14045
|
+
Content-Length:
|
14046
|
+
- '497'
|
14047
|
+
Connection:
|
14048
|
+
- Keep-Alive
|
14049
|
+
body:
|
14050
|
+
encoding: UTF-8
|
14051
|
+
string: |-
|
14052
|
+
{
|
14053
|
+
"id": 17,
|
14054
|
+
"text": "Do you like poptarts?",
|
14055
|
+
"question_type": "boolean",
|
14056
|
+
"responses": [
|
14057
|
+
"t",
|
14058
|
+
"f"
|
14059
|
+
],
|
14060
|
+
"answer": null,
|
14061
|
+
"_links": {
|
14062
|
+
"self": {
|
14063
|
+
"href": "http://localhost:3000/api/surveys/56/survey_questions/17"
|
14064
|
+
},
|
14065
|
+
"put": {
|
14066
|
+
"href": "http://localhost:3000/api/surveys/56/survey_questions/17"
|
14067
|
+
},
|
14068
|
+
"survey": {
|
14069
|
+
"href": "http://localhost:3000/api/surveys/56"
|
14070
|
+
}
|
14071
|
+
},
|
14072
|
+
"created_at": "2015-01-17T14:15:00.471Z",
|
14073
|
+
"key": null,
|
14074
|
+
"question_id": 63
|
14075
|
+
}
|
14076
|
+
http_version:
|
14077
|
+
recorded_at: Sat, 17 Jan 2015 14:15:00 GMT
|
14078
|
+
recorded_with: VCR 2.9.3
|