schemer_rails 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: b1363cff8a13a68db2bfb1f0c8af5f8e1b9b0965
4
- data.tar.gz: cecff424f61f3f6e42b6b2b206475770f945815a
3
+ metadata.gz: 14ed9d973d3526181eae8baf3daf50b6ef1b50a4
4
+ data.tar.gz: 43a9a89cd06a2a6d8c6c36489782b94a81377978
5
5
  SHA512:
6
- metadata.gz: 74db4db332b0db4f432fd8fca55c51cdc02f8d1b5bab767dd8a0a3528217678d264ea1d93cb06bdaae75e687f9545894064baaa7bd0769807c86a491019a57c9
7
- data.tar.gz: 6d19425dfe5d04287b00c4444b5417f3a1763c187049b0e16a12cbefb6cecd28847e21c4a1eddb7f7cc6ca40fdf93c81f76b76f95bdb1b7c9439e84ba8785633
6
+ metadata.gz: 5da88980d1c7e1aef0509adc3d0fc3e34bfcafb7aaf6dbffd986d4054040f40be47a88b1bf4215c050eb81abbca02653a430551a8ccff036f3a817c588238ef6
7
+ data.tar.gz: 80c414642bbfcf43063f86422bf948832dde6602ca1464b944537eee7b1281b2349254cd4446173675b7dd8d48b0aba07460cadc78a9ed7f1a56bd0cb3722efa
@@ -1,3 +1,3 @@
1
1
  module Schemer
2
- VERSION = "0.0.1"
2
+ VERSION = "0.0.2"
3
3
  end
data/lib/schemer.rb CHANGED
@@ -1,6 +1 @@
1
- require "schemer/engine"
2
- require "schemer/acts_as_surveyor"
3
-
4
- module Schemer
5
-
6
- end
1
+ require 'schemer_rails'
@@ -0,0 +1,6 @@
1
+ require "schemer/engine"
2
+ require "schemer/acts_as_surveyor"
3
+
4
+ module Schemer
5
+
6
+ end
@@ -5255,3 +5255,135 @@ LINE 1: ...eyable_id IS NULL) OR (schemer_surveyors.surveyable_id != 1)
5255
5255
   (1.2ms) SELECT COUNT(*) FROM "schemer_surveys" LEFT JOIN schemer_surveyors ON schemer_surveyors.survey_id = schemer_surveys.id WHERE ((schemer_surveyors.surveyable_id IS NULL) OR (schemer_surveyors.surveyable_id != 1 AND schemer_surveyors.surveyable_type = 'User'))
5256
5256
   (0.3ms) ROLLBACK TO SAVEPOINT active_record_1
5257
5257
   (0.3ms) ROLLBACK
5258
+  (7.4ms) ALTER TABLE "schemer_surveys" DISABLE TRIGGER ALL;ALTER TABLE "schema_migrations" DISABLE TRIGGER ALL;ALTER TABLE "schemer_questions" DISABLE TRIGGER ALL;ALTER TABLE "schemer_options" DISABLE TRIGGER ALL;ALTER TABLE "schemer_answers" DISABLE TRIGGER ALL;ALTER TABLE "schemer_surveyors" DISABLE TRIGGER ALL;ALTER TABLE "users" DISABLE TRIGGER ALL
5259
+  (7.4ms) select table_name from information_schema.views where table_schema = 'schemer_test'
5260
+  (23.0ms) TRUNCATE TABLE "schemer_surveys", "schemer_questions", "schemer_options", "schemer_answers", "schemer_surveyors", "users" RESTART IDENTITY CASCADE;
5261
+  (0.7ms) ALTER TABLE "schemer_surveys" ENABLE TRIGGER ALL;ALTER TABLE "schema_migrations" ENABLE TRIGGER ALL;ALTER TABLE "schemer_questions" ENABLE TRIGGER ALL;ALTER TABLE "schemer_options" ENABLE TRIGGER ALL;ALTER TABLE "schemer_answers" ENABLE TRIGGER ALL;ALTER TABLE "schemer_surveyors" ENABLE TRIGGER ALL;ALTER TABLE "users" ENABLE TRIGGER ALL
5262
+  (1.0ms) BEGIN
5263
+  (0.9ms) SAVEPOINT active_record_1
5264
+  (0.1ms) RELEASE SAVEPOINT active_record_1
5265
+  (0.1ms) SAVEPOINT active_record_1
5266
+  (0.3ms) SAVEPOINT active_record_2
5267
+ SQL (26.4ms) INSERT INTO "schemer_surveys" ("created_at", "description", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:44.014926"], ["description", "test"], ["title", "test"], ["updated_at", "2014-09-25 13:30:44.014926"]]
5268
+ SQL (0.9ms) INSERT INTO "schemer_questions" ("created_at", "survey_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:44.070785"], ["survey_id", 1], ["title", "q1"], ["updated_at", "2014-09-25 13:30:44.070785"]]
5269
+ SQL (0.7ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:44.073665"], ["question_id", 1], ["title", "a1"], ["updated_at", "2014-09-25 13:30:44.073665"]]
5270
+ SQL (0.5ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:44.075769"], ["question_id", 1], ["title", "a2"], ["updated_at", "2014-09-25 13:30:44.075769"]]
5271
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:44.077021"], ["question_id", 1], ["title", "a3"], ["updated_at", "2014-09-25 13:30:44.077021"]]
5272
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:44.078064"], ["question_id", 1], ["title", "a4"], ["updated_at", "2014-09-25 13:30:44.078064"]]
5273
+ SQL (0.5ms) INSERT INTO "schemer_questions" ("created_at", "survey_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:44.079215"], ["survey_id", 1], ["title", "q2"], ["updated_at", "2014-09-25 13:30:44.079215"]]
5274
+ SQL (0.4ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:44.080528"], ["question_id", 2], ["title", "a1"], ["updated_at", "2014-09-25 13:30:44.080528"]]
5275
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:44.081810"], ["question_id", 2], ["title", "a2"], ["updated_at", "2014-09-25 13:30:44.081810"]]
5276
+ SQL (0.4ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:44.082887"], ["question_id", 2], ["title", "a3"], ["updated_at", "2014-09-25 13:30:44.082887"]]
5277
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:44.083995"], ["question_id", 2], ["title", "a4"], ["updated_at", "2014-09-25 13:30:44.083995"]]
5278
+ SQL (0.6ms) INSERT INTO "schemer_questions" ("created_at", "survey_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:44.085100"], ["survey_id", 1], ["title", "q3"], ["updated_at", "2014-09-25 13:30:44.085100"]]
5279
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:44.086506"], ["question_id", 3], ["title", "a1"], ["updated_at", "2014-09-25 13:30:44.086506"]]
5280
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:44.087556"], ["question_id", 3], ["title", "a2"], ["updated_at", "2014-09-25 13:30:44.087556"]]
5281
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:44.088559"], ["question_id", 3], ["title", "a3"], ["updated_at", "2014-09-25 13:30:44.088559"]]
5282
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:44.089633"], ["question_id", 3], ["title", "a4"], ["updated_at", "2014-09-25 13:30:44.089633"]]
5283
+  (0.2ms) RELEASE SAVEPOINT active_record_2
5284
+  (0.3ms) SAVEPOINT active_record_2
5285
+ SQL (6.5ms) INSERT INTO "schemer_surveyors" ("created_at", "survey_id", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["created_at", "2014-09-25 13:30:44.099194"], ["survey_id", 1], ["updated_at", "2014-09-25 13:30:44.099194"]]
5286
+  (0.3ms) RELEASE SAVEPOINT active_record_2
5287
+ Schemer::Question Load (0.5ms) SELECT "schemer_questions".* FROM "schemer_questions" WHERE "schemer_questions"."survey_id" = $1 [["survey_id", 1]]
5288
+ Schemer::Option Load (0.5ms) SELECT "schemer_options".* FROM "schemer_options" WHERE "schemer_options"."question_id" = $1 [["question_id", 1]]
5289
+ Schemer::Question Load (0.4ms) SELECT "schemer_questions".* FROM "schemer_questions" WHERE "schemer_questions"."id" = $1 LIMIT 1 [["id", 1]]
5290
+  (0.2ms) SAVEPOINT active_record_2
5291
+ SQL (0.8ms) INSERT INTO "schemer_answers" ("created_at", "option_id", "question_id", "surveyor_id", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2014-09-25 13:30:44.135729"], ["option_id", 1], ["question_id", 1], ["surveyor_id", 1], ["updated_at", "2014-09-25 13:30:44.135729"]]
5292
+  (0.2ms) RELEASE SAVEPOINT active_record_2
5293
+  (1.6ms) ROLLBACK TO SAVEPOINT active_record_1
5294
+  (0.9ms) ROLLBACK
5295
+  (0.1ms) BEGIN
5296
+  (0.1ms) SAVEPOINT active_record_1
5297
+  (0.1ms) RELEASE SAVEPOINT active_record_1
5298
+  (0.1ms) SAVEPOINT active_record_1
5299
+  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1
5300
+  (0.1ms) ROLLBACK
5301
+  (0.1ms) BEGIN
5302
+  (0.1ms) SAVEPOINT active_record_1
5303
+  (0.1ms) RELEASE SAVEPOINT active_record_1
5304
+  (0.1ms) SAVEPOINT active_record_1
5305
+  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1
5306
+  (0.1ms) ROLLBACK
5307
+  (1.4ms) ALTER TABLE "schemer_surveys" DISABLE TRIGGER ALL;ALTER TABLE "schema_migrations" DISABLE TRIGGER ALL;ALTER TABLE "schemer_questions" DISABLE TRIGGER ALL;ALTER TABLE "schemer_options" DISABLE TRIGGER ALL;ALTER TABLE "schemer_answers" DISABLE TRIGGER ALL;ALTER TABLE "schemer_surveyors" DISABLE TRIGGER ALL;ALTER TABLE "users" DISABLE TRIGGER ALL
5308
+  (3.0ms) select table_name from information_schema.views where table_schema = 'schemer_test'
5309
+  (14.4ms) TRUNCATE TABLE "schemer_surveys", "schemer_questions", "schemer_options", "schemer_answers", "schemer_surveyors", "users" RESTART IDENTITY CASCADE;
5310
+  (0.8ms) ALTER TABLE "schemer_surveys" ENABLE TRIGGER ALL;ALTER TABLE "schema_migrations" ENABLE TRIGGER ALL;ALTER TABLE "schemer_questions" ENABLE TRIGGER ALL;ALTER TABLE "schemer_options" ENABLE TRIGGER ALL;ALTER TABLE "users" ENABLE TRIGGER ALL;ALTER TABLE "schemer_answers" ENABLE TRIGGER ALL;ALTER TABLE "schemer_surveyors" ENABLE TRIGGER ALL
5311
+  (0.2ms) BEGIN
5312
+  (0.2ms) SAVEPOINT active_record_1
5313
+  (0.1ms) RELEASE SAVEPOINT active_record_1
5314
+  (0.1ms) SAVEPOINT active_record_1
5315
+  (0.3ms) SAVEPOINT active_record_2
5316
+ SQL (0.9ms) INSERT INTO "schemer_surveys" ("created_at", "description", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.264427"], ["description", "test"], ["title", "test"], ["updated_at", "2014-09-25 13:30:54.264427"]]
5317
+ SQL (0.7ms) INSERT INTO "schemer_questions" ("created_at", "survey_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.269370"], ["survey_id", 1], ["title", "q1"], ["updated_at", "2014-09-25 13:30:54.269370"]]
5318
+ SQL (0.6ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.271451"], ["question_id", 1], ["title", "a1"], ["updated_at", "2014-09-25 13:30:54.271451"]]
5319
+ SQL (0.4ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.273409"], ["question_id", 1], ["title", "a2"], ["updated_at", "2014-09-25 13:30:54.273409"]]
5320
+ SQL (0.4ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.274761"], ["question_id", 1], ["title", "a3"], ["updated_at", "2014-09-25 13:30:54.274761"]]
5321
+ SQL (0.4ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.275926"], ["question_id", 1], ["title", "a4"], ["updated_at", "2014-09-25 13:30:54.275926"]]
5322
+ SQL (0.4ms) INSERT INTO "schemer_questions" ("created_at", "survey_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.277118"], ["survey_id", 1], ["title", "q2"], ["updated_at", "2014-09-25 13:30:54.277118"]]
5323
+ SQL (0.4ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.278280"], ["question_id", 2], ["title", "a1"], ["updated_at", "2014-09-25 13:30:54.278280"]]
5324
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.279418"], ["question_id", 2], ["title", "a2"], ["updated_at", "2014-09-25 13:30:54.279418"]]
5325
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.280492"], ["question_id", 2], ["title", "a3"], ["updated_at", "2014-09-25 13:30:54.280492"]]
5326
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.281493"], ["question_id", 2], ["title", "a4"], ["updated_at", "2014-09-25 13:30:54.281493"]]
5327
+ SQL (0.4ms) INSERT INTO "schemer_questions" ("created_at", "survey_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.282650"], ["survey_id", 1], ["title", "q3"], ["updated_at", "2014-09-25 13:30:54.282650"]]
5328
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.283848"], ["question_id", 3], ["title", "a1"], ["updated_at", "2014-09-25 13:30:54.283848"]]
5329
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.284955"], ["question_id", 3], ["title", "a2"], ["updated_at", "2014-09-25 13:30:54.284955"]]
5330
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.285976"], ["question_id", 3], ["title", "a3"], ["updated_at", "2014-09-25 13:30:54.285976"]]
5331
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.286963"], ["question_id", 3], ["title", "a4"], ["updated_at", "2014-09-25 13:30:54.286963"]]
5332
+  (0.2ms) RELEASE SAVEPOINT active_record_2
5333
+  (0.3ms) SAVEPOINT active_record_2
5334
+ SQL (0.5ms) INSERT INTO "schemer_surveys" ("created_at", "description", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.293789"], ["description", "test"], ["title", "test"], ["updated_at", "2014-09-25 13:30:54.293789"]]
5335
+ SQL (0.4ms) INSERT INTO "schemer_questions" ("created_at", "survey_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.295171"], ["survey_id", 2], ["title", "q1"], ["updated_at", "2014-09-25 13:30:54.295171"]]
5336
+ SQL (0.4ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.296329"], ["question_id", 4], ["title", "a1"], ["updated_at", "2014-09-25 13:30:54.296329"]]
5337
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.297535"], ["question_id", 4], ["title", "a2"], ["updated_at", "2014-09-25 13:30:54.297535"]]
5338
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.298598"], ["question_id", 4], ["title", "a3"], ["updated_at", "2014-09-25 13:30:54.298598"]]
5339
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.299645"], ["question_id", 4], ["title", "a4"], ["updated_at", "2014-09-25 13:30:54.299645"]]
5340
+ SQL (0.4ms) INSERT INTO "schemer_questions" ("created_at", "survey_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.300789"], ["survey_id", 2], ["title", "q2"], ["updated_at", "2014-09-25 13:30:54.300789"]]
5341
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.301912"], ["question_id", 5], ["title", "a1"], ["updated_at", "2014-09-25 13:30:54.301912"]]
5342
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.302968"], ["question_id", 5], ["title", "a2"], ["updated_at", "2014-09-25 13:30:54.302968"]]
5343
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.303959"], ["question_id", 5], ["title", "a3"], ["updated_at", "2014-09-25 13:30:54.303959"]]
5344
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.305086"], ["question_id", 5], ["title", "a4"], ["updated_at", "2014-09-25 13:30:54.305086"]]
5345
+ SQL (0.4ms) INSERT INTO "schemer_questions" ("created_at", "survey_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.306209"], ["survey_id", 2], ["title", "q3"], ["updated_at", "2014-09-25 13:30:54.306209"]]
5346
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.307378"], ["question_id", 6], ["title", "a1"], ["updated_at", "2014-09-25 13:30:54.307378"]]
5347
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.308522"], ["question_id", 6], ["title", "a2"], ["updated_at", "2014-09-25 13:30:54.308522"]]
5348
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.309548"], ["question_id", 6], ["title", "a3"], ["updated_at", "2014-09-25 13:30:54.309548"]]
5349
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.310548"], ["question_id", 6], ["title", "a4"], ["updated_at", "2014-09-25 13:30:54.310548"]]
5350
+  (0.2ms) RELEASE SAVEPOINT active_record_2
5351
+  (0.4ms) SAVEPOINT active_record_2
5352
+ SQL (0.5ms) INSERT INTO "schemer_surveys" ("created_at", "description", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.317438"], ["description", "test"], ["title", "test"], ["updated_at", "2014-09-25 13:30:54.317438"]]
5353
+ SQL (0.5ms) INSERT INTO "schemer_questions" ("created_at", "survey_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.319131"], ["survey_id", 3], ["title", "q1"], ["updated_at", "2014-09-25 13:30:54.319131"]]
5354
+ SQL (0.4ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.321073"], ["question_id", 7], ["title", "a1"], ["updated_at", "2014-09-25 13:30:54.321073"]]
5355
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.322726"], ["question_id", 7], ["title", "a2"], ["updated_at", "2014-09-25 13:30:54.322726"]]
5356
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.324042"], ["question_id", 7], ["title", "a3"], ["updated_at", "2014-09-25 13:30:54.324042"]]
5357
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.325140"], ["question_id", 7], ["title", "a4"], ["updated_at", "2014-09-25 13:30:54.325140"]]
5358
+ SQL (0.3ms) INSERT INTO "schemer_questions" ("created_at", "survey_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.326272"], ["survey_id", 3], ["title", "q2"], ["updated_at", "2014-09-25 13:30:54.326272"]]
5359
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.327365"], ["question_id", 8], ["title", "a1"], ["updated_at", "2014-09-25 13:30:54.327365"]]
5360
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.328531"], ["question_id", 8], ["title", "a2"], ["updated_at", "2014-09-25 13:30:54.328531"]]
5361
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.329641"], ["question_id", 8], ["title", "a3"], ["updated_at", "2014-09-25 13:30:54.329641"]]
5362
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.330714"], ["question_id", 8], ["title", "a4"], ["updated_at", "2014-09-25 13:30:54.330714"]]
5363
+ SQL (0.4ms) INSERT INTO "schemer_questions" ("created_at", "survey_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.331844"], ["survey_id", 3], ["title", "q3"], ["updated_at", "2014-09-25 13:30:54.331844"]]
5364
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.332995"], ["question_id", 9], ["title", "a1"], ["updated_at", "2014-09-25 13:30:54.332995"]]
5365
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.334087"], ["question_id", 9], ["title", "a2"], ["updated_at", "2014-09-25 13:30:54.334087"]]
5366
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.335124"], ["question_id", 9], ["title", "a3"], ["updated_at", "2014-09-25 13:30:54.335124"]]
5367
+ SQL (0.3ms) INSERT INTO "schemer_options" ("created_at", "question_id", "title", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.336116"], ["question_id", 9], ["title", "a4"], ["updated_at", "2014-09-25 13:30:54.336116"]]
5368
+  (0.2ms) RELEASE SAVEPOINT active_record_2
5369
+  (0.3ms) SAVEPOINT active_record_2
5370
+ SQL (0.7ms) INSERT INTO "users" ("created_at", "email", "name", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.345593"], ["email", "MyString"], ["name", "MyString"], ["updated_at", "2014-09-25 13:30:54.345593"]]
5371
+  (0.2ms) RELEASE SAVEPOINT active_record_2
5372
+  (0.2ms) SAVEPOINT active_record_2
5373
+ SQL (0.7ms) INSERT INTO "schemer_surveyors" ("created_at", "survey_id", "surveyable_id", "surveyable_type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2014-09-25 13:30:54.361804"], ["survey_id", 2], ["surveyable_id", 1], ["surveyable_type", "User"], ["updated_at", "2014-09-25 13:30:54.361804"]]
5374
+  (0.2ms) RELEASE SAVEPOINT active_record_2
5375
+  (0.2ms) SAVEPOINT active_record_2
5376
+ SQL (0.5ms) INSERT INTO "users" ("created_at", "email", "name", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["created_at", "2014-09-25 13:30:54.365113"], ["email", "MyString"], ["name", "MyString"], ["updated_at", "2014-09-25 13:30:54.365113"]]
5377
+  (0.2ms) RELEASE SAVEPOINT active_record_2
5378
+  (0.2ms) SAVEPOINT active_record_2
5379
+ SQL (0.4ms) INSERT INTO "schemer_surveyors" ("created_at", "survey_id", "surveyable_id", "surveyable_type", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2014-09-25 13:30:54.368177"], ["survey_id", 1], ["surveyable_id", 2], ["surveyable_type", "User"], ["updated_at", "2014-09-25 13:30:54.368177"]]
5380
+  (0.2ms) RELEASE SAVEPOINT active_record_2
5381
+ Schemer::Question Load (0.5ms) SELECT "schemer_questions".* FROM "schemer_questions" WHERE "schemer_questions"."survey_id" = $1 [["survey_id", 2]]
5382
+ Schemer::Option Load (0.5ms) SELECT "schemer_options".* FROM "schemer_options" WHERE "schemer_options"."question_id" = $1 [["question_id", 4]]
5383
+ Schemer::Question Load (0.4ms) SELECT "schemer_questions".* FROM "schemer_questions" WHERE "schemer_questions"."id" = $1 LIMIT 1 [["id", 4]]
5384
+  (0.2ms) SAVEPOINT active_record_2
5385
+ SQL (0.8ms) INSERT INTO "schemer_answers" ("created_at", "option_id", "question_id", "surveyor_id", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["created_at", "2014-09-25 13:30:54.393733"], ["option_id", 13], ["question_id", 4], ["surveyor_id", 1], ["updated_at", "2014-09-25 13:30:54.393733"]]
5386
+  (0.4ms) RELEASE SAVEPOINT active_record_2
5387
+  (1.3ms) SELECT COUNT(*) FROM "schemer_surveys" LEFT JOIN schemer_surveyors ON schemer_surveyors.survey_id = schemer_surveys.id WHERE ((schemer_surveyors.surveyable_id IS NULL) OR (schemer_surveyors.surveyable_id != 1 AND schemer_surveyors.surveyable_type = 'User'))
5388
+  (0.4ms) ROLLBACK TO SAVEPOINT active_record_1
5389
+  (0.2ms) ROLLBACK
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: schemer_rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Pranav Dhar
@@ -220,6 +220,7 @@ files:
220
220
  - lib/schemer/acts_as_surveyor.rb
221
221
  - lib/schemer/engine.rb
222
222
  - lib/schemer/version.rb
223
+ - lib/schemer_rails.rb
223
224
  - lib/tasks/schemer_tasks.rake
224
225
  - spec/controllers/schemer/surveys_controller_spec.rb
225
226
  - spec/dummy/README.rdoc