(1.3ms) CREATE TABLE "commontator_comments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "creator_type" varchar(255), "creator_id" integer, "editor_type" varchar(255), "editor_id" integer, "thread_id" integer NOT NULL, "body" text NOT NULL, "deleted_at" datetime, "cached_votes_up" integer DEFAULT 0, "cached_votes_down" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime)   (0.1ms) select sqlite_version(*)  (0.8ms) CREATE INDEX "index_commontator_comments_on_cached_votes_down" ON "commontator_comments" ("cached_votes_down")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'  (0.9ms) CREATE INDEX "index_commontator_comments_on_cached_votes_up" ON "commontator_comments" ("cached_votes_up")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.7ms) CREATE INDEX "index_commontator_comments_on_c_id_and_c_type_and_t_id" ON "commontator_comments" ("creator_id", "creator_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_comments_on_thread_id" ON "commontator_comments" ("thread_id")  (0.8ms) CREATE TABLE "commontator_subscriptions" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "subscriber_type" varchar(255) NOT NULL, "subscriber_id" integer NOT NULL, "thread_id" integer NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE UNIQUE INDEX "index_commontator_subscriptions_on_s_id_and_s_type_and_t_id" ON "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_subscriptions_on_thread_id" ON "commontator_subscriptions" ("thread_id")  (0.8ms) CREATE TABLE "commontator_threads" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "commontable_type" varchar(255), "commontable_id" integer, "closed_at" datetime, "closer_type" varchar(255), "closer_id" integer, "created_at" datetime, "updated_at" datetime)   (0.7ms) CREATE UNIQUE INDEX "index_commontator_threads_on_c_id_and_c_type" ON "commontator_threads" ("commontable_id", "commontable_type")  (0.8ms) CREATE TABLE "dummy_models" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.9ms) CREATE TABLE "dummy_users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)  (0.8ms) CREATE TABLE "votes" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "votable_id" integer, "votable_type" varchar(255), "voter_id" integer, "voter_type" varchar(255), "vote_flag" boolean, "vote_scope" varchar(255), "vote_weight" integer, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE INDEX "index_votes_on_votable_id_and_votable_type_and_vote_scope" ON "votes" ("votable_id", "votable_type", "vote_scope")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index'   (0.8ms) CREATE INDEX "index_votes_on_voter_id_and_voter_type_and_vote_scope" ON "votes" ("voter_id", "voter_type", "vote_scope")  (0.9ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)   (1.0ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.1ms) SELECT version FROM "schema_migrations"  (0.8ms) INSERT INTO "schema_migrations" (version) VALUES ('3')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('1')  (0.6ms) INSERT INTO "schema_migrations" (version) VALUES ('2')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.0ms) begin transaction SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.316185"], ["updated_at", "2014-09-17 00:32:36.316185"]]  (0.7ms) commit transaction  (0.0ms) begin transaction ---------------------------------------------------------------------- Commontator::ThreadsController: test_0001_won't show unless authorized ----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.323681"], ["updated_at", "2014-09-17 00:32:36.323681"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.326025"], ["updated_at", "2014-09-17 00:32:36.326025"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.327354"], ["updated_at", "2014-09-17 00:32:36.327354"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.2ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 6ms (ActiveRecord: 0.3ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::ThreadsController: test_0002_must show if authorized -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.340197"], ["updated_at", "2014-09-17 00:32:36.340197"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.341366"], ["updated_at", "2014-09-17 00:32:36.341366"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.342262"], ["updated_at", "2014-09-17 00:32:36.342262"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 2], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.2ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/2 Completed 302 Found in 13ms (ActiveRecord: 0.7ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 2], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/2 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 2], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/2 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------------------- Commontator::ThreadsController: test_0003_won't close unless authorized and open --------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.363835"], ["updated_at", "2014-09-17 00:32:36.363835"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.365029"], ["updated_at", "2014-09-17 00:32:36.365029"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.365976"], ["updated_at", "2014-09-17 00:32:36.365976"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-09-17 00:32:36.370762"], ["updated_at", "2014-09-17 00:32:36.378286"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------- Commontator::ThreadsController: test_0004_must close if authorized and open ---------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.384337"], ["updated_at", "2014-09-17 00:32:36.384337"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.385631"], ["updated_at", "2014-09-17 00:32:36.385631"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.386606"], ["updated_at", "2014-09-17 00:32:36.386606"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-09-17 00:32:36.389738"], ["closer_id", 1], ["closer_type", "DummyUser"], ["updated_at", "2014-09-17 00:32:36.390862"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.4ms)  (0.1ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-09-17 00:32:36.394520"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-09-17 00:32:36.397111"], ["updated_at", "2014-09-17 00:32:36.398266"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.3ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------------------------- Commontator::ThreadsController: test_0005_won't reopen unless authorized and closed -----------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.402005"], ["updated_at", "2014-09-17 00:32:36.402005"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.403856"], ["updated_at", "2014-09-17 00:32:36.403856"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.405307"], ["updated_at", "2014-09-17 00:32:36.405307"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-09-17 00:32:36.406132"], ["updated_at", "2014-09-17 00:32:36.407079"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-09-17 00:32:36.414202"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::ThreadsController: test_0006_must reopen if authorized and closed ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.418267"], ["updated_at", "2014-09-17 00:32:36.418267"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.419388"], ["updated_at", "2014-09-17 00:32:36.419388"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.420290"], ["updated_at", "2014-09-17 00:32:36.420290"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-09-17 00:32:36.420829"], ["updated_at", "2014-09-17 00:32:36.421548"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.0ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-09-17 00:32:36.424226"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-09-17 00:32:36.425472"], ["updated_at", "2014-09-17 00:32:36.426122"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-09-17 00:32:36.428392"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------- Commontator::SharedHelper: test_0001_must show commontator thread -----------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.437522"], ["updated_at", "2014-09-17 00:32:36.437522"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.438758"], ["updated_at", "2014-09-17 00:32:36.438758"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 1]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/shared/_thread.html.erb (14.8ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------------- Commontator::CommentsController: test_0001_won't get new unless authorized --------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.464818"], ["updated_at", "2014-09-17 00:32:36.464818"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.466134"], ["updated_at", "2014-09-17 00:32:36.466134"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.467819"], ["updated_at", "2014-09-17 00:32:36.467819"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:36.474941"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.474941"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------- Commontator::CommentsController: test_0002_must get new if authorized ---------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.490215"], ["updated_at", "2014-09-17 00:32:36.490215"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.491443"], ["updated_at", "2014-09-17 00:32:36.491443"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.492345"], ["updated_at", "2014-09-17 00:32:36.492345"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:36.494046"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.494046"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 1ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0003_won't create unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.503953"], ["updated_at", "2014-09-17 00:32:36.503953"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.505161"], ["updated_at", "2014-09-17 00:32:36.505161"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.506091"], ["updated_at", "2014-09-17 00:32:36.506091"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:36.507747"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.507747"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-09-17 00:32:36.510696"], ["updated_at", "2014-09-17 00:32:36.511434"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0004_must create if authorized --------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.515647"], ["updated_at", "2014-09-17 00:32:36.515647"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.517480"], ["updated_at", "2014-09-17 00:32:36.517480"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.519023"], ["updated_at", "2014-09-17 00:32:36.519023"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:36.521380"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.521380"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:36.525626"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.525626"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Another thing"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Another thing' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Another thing"], ["created_at", "2014-09-17 00:32:36.530714"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.530714"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"And this too"}} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'And this too' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "And this too"], ["created_at", "2014-09-17 00:32:36.534574"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.534574"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0005_won't create if double posting -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.537656"], ["updated_at", "2014-09-17 00:32:36.537656"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.538904"], ["updated_at", "2014-09-17 00:32:36.538904"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.539798"], ["updated_at", "2014-09-17 00:32:36.539798"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:36.541382"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.541382"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something"}} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:36.548428"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.548428"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------- Commontator::CommentsController: test_0006_won't edit unless authorized -----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.555913"], ["updated_at", "2014-09-17 00:32:36.555913"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.557076"], ["updated_at", "2014-09-17 00:32:36.557076"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.557992"], ["updated_at", "2014-09-17 00:32:36.557992"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:36.559480"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.559480"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.564027"], ["updated_at", "2014-09-17 00:32:36.564027"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms)  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:36.567520"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.567520"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------ Commontator::CommentsController: test_0007_must edit if authorized ------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.571822"], ["updated_at", "2014-09-17 00:32:36.571822"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.572828"], ["updated_at", "2014-09-17 00:32:36.572828"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.573725"], ["updated_at", "2014-09-17 00:32:36.573725"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:36.575210"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.575210"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0008_won't update unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.586888"], ["updated_at", "2014-09-17 00:32:36.586888"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.588180"], ["updated_at", "2014-09-17 00:32:36.588180"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.589268"], ["updated_at", "2014-09-17 00:32:36.589268"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:36.590888"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.590888"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.596261"], ["updated_at", "2014-09-17 00:32:36.596261"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:36.600510"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.600510"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.5ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0009_must update if authorized --------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.606247"], ["updated_at", "2014-09-17 00:32:36.606247"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.608154"], ["updated_at", "2014-09-17 00:32:36.608154"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.609661"], ["updated_at", "2014-09-17 00:32:36.609661"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:36.612058"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.612058"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["body", "Something else"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-09-17 00:32:36.617681"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------------------------------- Commontator::CommentsController: test_0010_won't delete unless authorized and not deleted -----------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.629084"], ["updated_at", "2014-09-17 00:32:36.629084"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.630272"], ["updated_at", "2014-09-17 00:32:36.630272"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.631180"], ["updated_at", "2014-09-17 00:32:36.631180"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:36.632705"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.632705"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-09-17 00:32:36.637634') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-09-17 00:32:36.637634"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-09-17 00:32:36.638986"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:36.644290"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.644290"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["updated_at", "2014-09-17 00:32:36.645892"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.4ms) rollback transaction  (0.2ms) begin transaction ------------------------------------------------------------------------------------ Commontator::CommentsController: test_0011_must delete if authorized and not deleted ------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.651089"], ["updated_at", "2014-09-17 00:32:36.651089"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.652269"], ["updated_at", "2014-09-17 00:32:36.652269"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.653187"], ["updated_at", "2014-09-17 00:32:36.653187"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:36.654823"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.654823"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-09-17 00:32:36.658320') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-09-17 00:32:36.658320"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-09-17 00:32:36.659198"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.661070"], ["updated_at", "2014-09-17 00:32:36.661070"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:36.662671"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.662671"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["updated_at", "2014-09-17 00:32:36.664192"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-09-17 00:32:36.666357') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-09-17 00:32:36.666357"], ["editor_id", 2], ["updated_at", "2014-09-17 00:32:36.667249"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["editor_id", 1], ["updated_at", "2014-09-17 00:32:36.669368"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-09-17 00:32:36.671609') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-09-17 00:32:36.671609"], ["editor_id", 2], ["updated_at", "2014-09-17 00:32:36.672533"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------------- Commontator::CommentsController: test_0012_won't undelete unless authorized and deleted ---------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.675131"], ["updated_at", "2014-09-17 00:32:36.675131"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.676208"], ["updated_at", "2014-09-17 00:32:36.676208"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.677136"], ["updated_at", "2014-09-17 00:32:36.677136"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:36.678752"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.678752"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-09-17 00:32:36.679392') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-09-17 00:32:36.679392"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-09-17 00:32:36.680204"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 9ms (ActiveRecord: 0.3ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["updated_at", "2014-09-17 00:32:36.692689"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.696862"], ["updated_at", "2014-09-17 00:32:36.696862"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-09-17 00:32:36.697419') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-09-17 00:32:36.697419"], ["editor_id", 2], ["updated_at", "2014-09-17 00:32:36.698283"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:36.702034"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.702034"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["editor_id", 1], ["updated_at", "2014-09-17 00:32:36.703989"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-09-17 00:32:36.704490') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-09-17 00:32:36.704490"], ["updated_at", "2014-09-17 00:32:36.705201"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------------------- Commontator::CommentsController: test_0013_must undelete if authorized and deleted ----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.710273"], ["updated_at", "2014-09-17 00:32:36.710273"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.711349"], ["updated_at", "2014-09-17 00:32:36.711349"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.712291"], ["updated_at", "2014-09-17 00:32:36.712291"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:36.713878"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.713878"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-09-17 00:32:36.714544') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-09-17 00:32:36.714544"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-09-17 00:32:36.715320"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["updated_at", "2014-09-17 00:32:36.720359"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.721985"], ["updated_at", "2014-09-17 00:32:36.721985"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:36.723383"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.723383"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-09-17 00:32:36.723979') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-09-17 00:32:36.723979"], ["updated_at", "2014-09-17 00:32:36.724795"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["editor_id", 2], ["updated_at", "2014-09-17 00:32:36.727658"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-09-17 00:32:36.728850') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-09-17 00:32:36.728850"], ["editor_id", 1], ["updated_at", "2014-09-17 00:32:36.729618"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["editor_id", 2], ["updated_at", "2014-09-17 00:32:36.732428"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0014_won't upvote unless authorized -------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.735551"], ["updated_at", "2014-09-17 00:32:36.735551"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.737189"], ["updated_at", "2014-09-17 00:32:36.737189"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.738699"], ["updated_at", "2014-09-17 00:32:36.738699"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:36.741034"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.741034"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.751629"], ["updated_at", "2014-09-17 00:32:36.751629"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.7ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0015_must upvote if authorized --------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.760364"], ["updated_at", "2014-09-17 00:32:36.760364"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.762329"], ["updated_at", "2014-09-17 00:32:36.762329"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.763828"], ["updated_at", "2014-09-17 00:32:36.763828"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:36.766280"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.766280"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.767526"], ["updated_at", "2014-09-17 00:32:36.767526"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:36.776469"], ["updated_at", "2014-09-17 00:32:36.776469"], ["votable_id", 1], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 10ms (ActiveRecord: 0.7ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-09-17 00:32:36.789528"], ["vote_flag", "f"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-09-17 00:32:36.795243"], ["vote_flag", "t"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------- Commontator::CommentsController: test_0016_won't downvote unless authorized ---------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.800471"], ["updated_at", "2014-09-17 00:32:36.800471"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.802414"], ["updated_at", "2014-09-17 00:32:36.802414"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.803391"], ["updated_at", "2014-09-17 00:32:36.803391"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:36.805040"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.805040"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.812267"], ["updated_at", "2014-09-17 00:32:36.812267"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------- Commontator::CommentsController: test_0017_must downvote if authorized ----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.817747"], ["updated_at", "2014-09-17 00:32:36.817747"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.818773"], ["updated_at", "2014-09-17 00:32:36.818773"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.819683"], ["updated_at", "2014-09-17 00:32:36.819683"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:36.821270"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.821270"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.822127"], ["updated_at", "2014-09-17 00:32:36.822127"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:36.826392"], ["updated_at", "2014-09-17 00:32:36.826392"], ["votable_id", 1], ["votable_type", "Commontator::Comment"], ["vote_flag", "f"], ["vote_weight", 1], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-09-17 00:32:36.840480"], ["vote_flag", "t"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-09-17 00:32:36.846498"], ["vote_flag", "f"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0018_won't unvote unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.852614"], ["updated_at", "2014-09-17 00:32:36.852614"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.853869"], ["updated_at", "2014-09-17 00:32:36.853869"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.854817"], ["updated_at", "2014-09-17 00:32:36.854817"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:36.856544"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.856544"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 1 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:36.858847"], ["updated_at", "2014-09-17 00:32:36.858847"], ["votable_id", 1], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 1], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.868170"], ["updated_at", "2014-09-17 00:32:36.868170"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.6ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0019_must unvote if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.874166"], ["updated_at", "2014-09-17 00:32:36.874166"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.875463"], ["updated_at", "2014-09-17 00:32:36.875463"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.876576"], ["updated_at", "2014-09-17 00:32:36.876576"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:36.878955"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.878955"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.880450"], ["updated_at", "2014-09-17 00:32:36.880450"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:36.883060"], ["updated_at", "2014-09-17 00:32:36.883060"], ["votable_id", 1], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.7ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:36.905528"], ["updated_at", "2014-09-17 00:32:36.905528"], ["votable_id", 1], ["votable_type", "Commontator::Comment"], ["vote_flag", "f"], ["vote_weight", 1], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::CommentsController: test_0020_won't send mail if recipients empty ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.916684"], ["updated_at", "2014-09-17 00:32:36.916684"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.917814"], ["updated_at", "2014-09-17 00:32:36.917814"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.918733"], ["updated_at", "2014-09-17 00:32:36.918733"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:36.920583"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.920583"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.921545"], ["updated_at", "2014-09-17 00:32:36.921545"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:36.924932"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.924932"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------- Commontator::CommentsController: test_0021_must send mail if recipients not empty ---------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.928125"], ["updated_at", "2014-09-17 00:32:36.928125"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.929225"], ["updated_at", "2014-09-17 00:32:36.929225"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.930247"], ["updated_at", "2014-09-17 00:32:36.930247"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:36.931757"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.931757"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.932629"], ["updated_at", "2014-09-17 00:32:36.932629"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:36.937539"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.937539"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:36.940991"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.940991"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.3ms)  (0.6ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0001_won't subscribe unless authorized ---------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.945781"], ["updated_at", "2014-09-17 00:32:36.945781"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.947076"], ["updated_at", "2014-09-17 00:32:36.947076"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.948358"], ["updated_at", "2014-09-17 00:32:36.948358"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:36.957155"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.957155"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0002_must subscribe if authorized ----------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.961959"], ["updated_at", "2014-09-17 00:32:36.961959"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.963064"], ["updated_at", "2014-09-17 00:32:36.963064"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.963987"], ["updated_at", "2014-09-17 00:32:36.963987"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:36.967464"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.967464"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:36.972824"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.972824"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:36.977434"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.977434"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.5ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0003_won't unsubscribe unless authorized -----------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.980998"], ["updated_at", "2014-09-17 00:32:36.980998"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.982922"], ["updated_at", "2014-09-17 00:32:36.982922"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.984421"], ["updated_at", "2014-09-17 00:32:36.984421"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:36.987319"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:36.987319"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::SubscriptionsController: test_0004_must unsubscribe if authorized ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.996660"], ["updated_at", "2014-09-17 00:32:36.996660"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:36.997838"], ["updated_at", "2014-09-17 00:32:36.997838"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:36.998754"], ["updated_at", "2014-09-17 00:32:36.998754"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:37.001535"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:37.001535"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:37.007365"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:37.007365"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:37.011912"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:37.011912"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 3]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.6ms) rollback transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.017424"], ["updated_at", "2014-09-17 00:32:37.017424"]]  (0.7ms) commit transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------- Commontator::Comment: test_0001_must be votable if acts_as_votable is installed -------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.020414"], ["updated_at", "2014-09-17 00:32:37.020414"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.021668"], ["updated_at", "2014-09-17 00:32:37.021668"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:37.022707"], ["updated_at", "2014-09-17 00:32:37.022707"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.3ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------- Commontator::Comment: test_0002_must know if it has been modified -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.024543"], ["updated_at", "2014-09-17 00:32:37.024543"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.025507"], ["updated_at", "2014-09-17 00:32:37.025507"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:37.026464"], ["updated_at", "2014-09-17 00:32:37.026464"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:37.028067"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:37.028067"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["body", "Something else"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-09-17 00:32:37.029465"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.3ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------- Commontator::Comment: test_0003_must know if it has been deleted ----------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.031062"], ["updated_at", "2014-09-17 00:32:37.031062"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.032107"], ["updated_at", "2014-09-17 00:32:37.032107"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:37.033020"], ["updated_at", "2014-09-17 00:32:37.033020"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-09-17 00:32:37.033948') LIMIT 1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.035209"], ["updated_at", "2014-09-17 00:32:37.035209"]] SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "deleted_at", "editor_id", "editor_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:37.035785"], ["creator_id", 2], ["creator_type", "DummyUser"], ["deleted_at", "2014-09-17 00:32:37.033948"], ["editor_id", 3], ["editor_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:37.035785"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["updated_at", "2014-09-17 00:32:37.037577"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------- Commontator::Comment: test_0004_must make proper timestamps -----------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.039266"], ["updated_at", "2014-09-17 00:32:37.039266"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.040541"], ["updated_at", "2014-09-17 00:32:37.040541"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:37.041567"], ["updated_at", "2014-09-17 00:32:37.041567"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:37.043215"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:37.043215"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.044757"], ["updated_at", "2014-09-17 00:32:37.044757"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["body", "Something else"], ["editor_id", 3], ["editor_type", "DummyUser"], ["updated_at", "2014-09-17 00:32:37.046063"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------ Commontator::SubscriptionsMailer: test_0001_must create deliverable mail ------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.052694"], ["updated_at", "2014-09-17 00:32:37.052694"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.054173"], ["updated_at", "2014-09-17 00:32:37.054173"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:37.055132"], ["updated_at", "2014-09-17 00:32:37.055132"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.055922"], ["updated_at", "2014-09-17 00:32:37.055922"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:37.058086"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:37.058086"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 3], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 3) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:37.059919"], ["subscriber_id", 3], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:37.059919"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:37.061490"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:37.061490"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 3]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/comments/_body.html.erb (3.1ms) Commontator::SubscriptionsMailer#comment_created: processed outbound mail in 19.2ms Sent mail to Undisclosed Recipients (12.6ms) Date: Tue, 16 Sep 2014 19:32:37 -0500 From: no-reply@dummy.com to: Undisclosed Recipients Message-ID: <5418d6a515b83_c6c3fcfbc82dbf87701a@Dantes-MacBook-Pro.local.mail> Subject: Dummy User #2 posted a comment on DummyModel #2 Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit

Dummy User #2 commented on DummyModel #2:

Something

Click here to view all comments on DummyModel #2.

 (0.6ms) rollback transaction  (0.1ms) begin transaction SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.103409"], ["updated_at", "2014-09-17 00:32:37.103409"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.106171"], ["updated_at", "2014-09-17 00:32:37.106171"]]  (0.7ms) commit transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:37.108277"], ["updated_at", "2014-09-17 00:32:37.108277"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-09-17 00:32:37.109926"], ["closer_id", 2], ["closer_type", "DummyUser"], ["updated_at", "2014-09-17 00:32:37.111056"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-09-17 00:32:37.113194"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.114612"], ["updated_at", "2014-09-17 00:32:37.114612"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.116241"], ["updated_at", "2014-09-17 00:32:37.116241"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 3], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:37.117702"], ["updated_at", "2014-09-17 00:32:37.117702"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.2ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 3], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 3) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:37.121043"], ["subscriber_id", 3], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-09-17 00:32:37.121043"]]  (0.5ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 3], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-09-17 00:32:37.121043') [["thread_id", 2]]  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 3 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:37.126735"], ["creator_id", 3], ["creator_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-09-17 00:32:37.126735"]]  (0.9ms) commit transaction Commontator::Subscription Load (0.2ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-09-17 00:32:37.121043') [["thread_id", 2]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 3], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction SQL (0.2ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-09-17 00:32:37.132427' WHERE "commontator_subscriptions"."id" = 1  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]]  (0.2ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-09-17 00:32:37.132427') [["thread_id", 2]]  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.137601"], ["updated_at", "2014-09-17 00:32:37.137601"]]  (0.7ms) commit transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.139736"], ["updated_at", "2014-09-17 00:32:37.139736"]]  (0.5ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 4], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:37.141372"], ["updated_at", "2014-09-17 00:32:37.141372"]]  (0.5ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 4 AND "commontator_comments"."thread_id" = 3 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:37.143993"], ["creator_id", 4], ["creator_type", "DummyUser"], ["thread_id", 3], ["updated_at", "2014-09-17 00:32:37.143993"]]  (0.5ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 4 AND "commontator_threads"."id" != 3 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 3 [["closed_at", "2014-09-17 00:32:37.145302"], ["closer_id", 4], ["closer_type", "DummyUser"], ["updated_at", "2014-09-17 00:32:37.146240"]]  (0.5ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 2 LIMIT 1 [["thread_id", 3]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 4]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 4], ["commontable_type", "DummyModel"]]  (0.0ms) begin transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 3]] SQL (0.2ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "commontable_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 3 [["commontable_id", nil], ["commontable_type", nil], ["updated_at", "2014-09-17 00:32:37.151328"]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 4 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 4], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:37.152647"], ["updated_at", "2014-09-17 00:32:37.152647"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 3]]  (0.5ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 2 LIMIT 1 [["thread_id", 3]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 4]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 4], ["commontable_type", "DummyModel"]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 2 LIMIT 1 [["thread_id", 4]]  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.156751"], ["updated_at", "2014-09-17 00:32:37.156751"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.158466"], ["updated_at", "2014-09-17 00:32:37.158466"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 5], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:37.159940"], ["updated_at", "2014-09-17 00:32:37.159940"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 5 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 5], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 5 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 5) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:37.163028"], ["subscriber_id", 5], ["subscriber_type", "DummyUser"], ["thread_id", 5], ["updated_at", "2014-09-17 00:32:37.163028"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.164610"], ["updated_at", "2014-09-17 00:32:37.164610"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 5 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 6], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 5 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 6) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:37.167188"], ["subscriber_id", 6], ["subscriber_type", "DummyUser"], ["thread_id", 5], ["updated_at", "2014-09-17 00:32:37.167188"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 5 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 5], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 5]] DummyUser Load (0.2ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 5]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 5 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 6], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 5]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 6]]  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.171595"], ["updated_at", "2014-09-17 00:32:37.171595"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.173399"], ["updated_at", "2014-09-17 00:32:37.173399"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 6], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:37.174898"], ["updated_at", "2014-09-17 00:32:37.174898"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 6 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 7], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 6 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 7) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:37.177727"], ["subscriber_id", 7], ["subscriber_type", "DummyUser"], ["thread_id", 6], ["updated_at", "2014-09-17 00:32:37.177727"]]  (0.7ms) commit transaction  (0.1ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.179267"], ["updated_at", "2014-09-17 00:32:37.179267"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 6 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 8], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 6 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 8) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:37.181791"], ["subscriber_id", 8], ["subscriber_type", "DummyUser"], ["thread_id", 6], ["updated_at", "2014-09-17 00:32:37.181791"]]  (0.5ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 6]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 7]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 8]]  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.184882"], ["updated_at", "2014-09-17 00:32:37.184882"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.186659"], ["updated_at", "2014-09-17 00:32:37.186659"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 7], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:37.188157"], ["updated_at", "2014-09-17 00:32:37.188157"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.189718"], ["updated_at", "2014-09-17 00:32:37.189718"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.191296"], ["updated_at", "2014-09-17 00:32:37.191296"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 8], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:37.192754"], ["updated_at", "2014-09-17 00:32:37.192754"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 10 AND "commontator_comments"."thread_id" = 8 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:37.195335"], ["creator_id", 10], ["creator_type", "DummyUser"], ["thread_id", 8], ["updated_at", "2014-09-17 00:32:37.195335"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 10 AND "commontator_comments"."thread_id" = 8 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:37.197530"], ["creator_id", 10], ["creator_type", "DummyUser"], ["thread_id", 8], ["updated_at", "2014-09-17 00:32:37.197530"]]  (0.7ms) commit transaction Commontator::Comment Load (0.2ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 8]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY created_at ASC [["thread_id", 8]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.200430"], ["updated_at", "2014-09-17 00:32:37.200430"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.202072"], ["updated_at", "2014-09-17 00:32:37.202072"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:37.203579"], ["updated_at", "2014-09-17 00:32:37.203579"]]  (0.7ms) commit transaction  (0.0ms) begin transaction DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", nil]] SQL (0.1ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 9 [["commontable_id", nil], ["updated_at", "2014-09-17 00:32:37.205586"]]  (0.6ms) commit transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) begin transaction --------------------------------------------------------------- Commontator::Subscription: test_0001_must count unread comments ---------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.208214"], ["updated_at", "2014-09-17 00:32:37.208214"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:37.209300"], ["updated_at", "2014-09-17 00:32:37.209300"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:37.210219"], ["updated_at", "2014-09-17 00:32:37.210219"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:37.211730"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:37.211730"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-09-17 00:32:37.211730') [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:37.214558"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:37.214558"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-09-17 00:32:37.211730') [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:37.218525"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:37.218525"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-09-17 00:32:37.211730') [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-09-17 00:32:37.222400' WHERE "commontator_subscriptions"."id" = 6  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-09-17 00:32:37.222400') [["thread_id", 10]]  (0.6ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::ApplicationHelper: test_0001_must print javascript proc --------------------------------------------------------------------  (0.1ms) rollback transaction  (1.8ms) CREATE TABLE "commontator_comments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "creator_type" varchar(255), "creator_id" integer, "editor_type" varchar(255), "editor_id" integer, "thread_id" integer NOT NULL, "body" text NOT NULL, "deleted_at" datetime, "cached_votes_up" integer DEFAULT 0, "cached_votes_down" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime)   (0.1ms) select sqlite_version(*)  (0.8ms) CREATE INDEX "index_commontator_comments_on_cached_votes_down" ON "commontator_comments" ("cached_votes_down")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'  (0.7ms) CREATE INDEX "index_commontator_comments_on_cached_votes_up" ON "commontator_comments" ("cached_votes_up")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.7ms) CREATE INDEX "index_commontator_comments_on_c_id_and_c_type_and_t_id" ON "commontator_comments" ("creator_id", "creator_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_comments_on_thread_id_and_created_at" ON "commontator_comments" ("thread_id", "created_at")  (0.8ms) CREATE TABLE "commontator_subscriptions" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "subscriber_type" varchar(255) NOT NULL, "subscriber_id" integer NOT NULL, "thread_id" integer NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE UNIQUE INDEX "index_commontator_subscriptions_on_s_id_and_s_type_and_t_id" ON "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_subscriptions_on_thread_id" ON "commontator_subscriptions" ("thread_id")  (0.8ms) CREATE TABLE "commontator_threads" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "commontable_type" varchar(255), "commontable_id" integer, "closed_at" datetime, "closer_type" varchar(255), "closer_id" integer, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE UNIQUE INDEX "index_commontator_threads_on_c_id_and_c_type" ON "commontator_threads" ("commontable_id", "commontable_type")  (0.8ms) CREATE TABLE "dummy_models" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE TABLE "dummy_users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)  (0.8ms) CREATE TABLE "votes" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "votable_id" integer, "votable_type" varchar(255), "voter_id" integer, "voter_type" varchar(255), "vote_flag" boolean, "vote_scope" varchar(255), "vote_weight" integer, "created_at" datetime, "updated_at" datetime)   (0.9ms) CREATE INDEX "index_votes_on_votable_id_and_votable_type_and_vote_scope" ON "votes" ("votable_id", "votable_type", "vote_scope")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index'   (0.8ms) CREATE INDEX "index_votes_on_voter_id_and_voter_type_and_vote_scope" ON "votes" ("voter_id", "voter_type", "vote_scope")  (0.6ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)   (1.0ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.1ms) SELECT version FROM "schema_migrations"  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('3')  (0.8ms) INSERT INTO "schema_migrations" (version) VALUES ('1')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('2')  (0.8ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::ApplicationHelper: test_0001_must print javascript proc --------------------------------------------------------------------  (0.0ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------ Commontator::SubscriptionsMailer: test_0001_must create deliverable mail ------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.029925"], ["updated_at", "2014-09-17 00:32:49.029925"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.046142"], ["updated_at", "2014-09-17 00:32:49.046142"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.048427"], ["updated_at", "2014-09-17 00:32:49.048427"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.049342"], ["updated_at", "2014-09-17 00:32:49.049342"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:49.065424"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:49.065424"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.0ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:49.067687"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:49.067687"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.074722"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:49.074722"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/comments/_body.html.erb (2.0ms) Commontator::SubscriptionsMailer#comment_created: processed outbound mail in 19.2ms Sent mail to Undisclosed Recipients (6.0ms) Date: Tue, 16 Sep 2014 19:32:49 -0500 From: no-reply@dummy.com to: Undisclosed Recipients Message-ID: <5418d6b118a8a_c7d3ffb58c2dbdc913b8@Dantes-MacBook-Pro.local.mail> Subject: Dummy User #1 posted a comment on DummyModel #1 Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit

Dummy User #1 commented on DummyModel #1:

Something

Click here to view all comments on DummyModel #1.

 (1.2ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------------- Commontator::ThreadsController: test_0001_won't show unless authorized ----------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.111750"], ["updated_at", "2014-09-17 00:32:49.111750"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.113841"], ["updated_at", "2014-09-17 00:32:49.113841"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.115278"], ["updated_at", "2014-09-17 00:32:49.115278"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::ThreadsController: test_0002_must show if authorized -----------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.123602"], ["updated_at", "2014-09-17 00:32:49.123602"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.124757"], ["updated_at", "2014-09-17 00:32:49.124757"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.125686"], ["updated_at", "2014-09-17 00:32:49.125686"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 1], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 1], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 1], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------------------- Commontator::ThreadsController: test_0003_won't close unless authorized and open --------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.136505"], ["updated_at", "2014-09-17 00:32:49.136505"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.137520"], ["updated_at", "2014-09-17 00:32:49.137520"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.138407"], ["updated_at", "2014-09-17 00:32:49.138407"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-09-17 00:32:49.142745"], ["updated_at", "2014-09-17 00:32:49.144018"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------- Commontator::ThreadsController: test_0004_must close if authorized and open ---------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.148902"], ["updated_at", "2014-09-17 00:32:49.148902"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.149969"], ["updated_at", "2014-09-17 00:32:49.149969"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.150878"], ["updated_at", "2014-09-17 00:32:49.150878"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-09-17 00:32:49.152823"], ["closer_id", 1], ["closer_type", "DummyUser"], ["updated_at", "2014-09-17 00:32:49.153582"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-09-17 00:32:49.156639"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-09-17 00:32:49.158359"], ["updated_at", "2014-09-17 00:32:49.159054"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------- Commontator::ThreadsController: test_0005_won't reopen unless authorized and closed -----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.161544"], ["updated_at", "2014-09-17 00:32:49.161544"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.163236"], ["updated_at", "2014-09-17 00:32:49.163236"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.164785"], ["updated_at", "2014-09-17 00:32:49.164785"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-09-17 00:32:49.165643"], ["updated_at", "2014-09-17 00:32:49.166587"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-09-17 00:32:49.174251"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------------ Commontator::ThreadsController: test_0006_must reopen if authorized and closed ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.185204"], ["updated_at", "2014-09-17 00:32:49.185204"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.186869"], ["updated_at", "2014-09-17 00:32:49.186869"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.188177"], ["updated_at", "2014-09-17 00:32:49.188177"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-09-17 00:32:49.189346"], ["updated_at", "2014-09-17 00:32:49.190331"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-09-17 00:32:49.193528"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.0ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-09-17 00:32:49.194913"], ["updated_at", "2014-09-17 00:32:49.195477"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-09-17 00:32:49.197604"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------- Commontator::Comment: test_0001_must be votable if acts_as_votable is installed -------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.204391"], ["updated_at", "2014-09-17 00:32:49.204391"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.205690"], ["updated_at", "2014-09-17 00:32:49.205690"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.206658"], ["updated_at", "2014-09-17 00:32:49.206658"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::Comment: test_0002_must know if it has been modified -----------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.211146"], ["updated_at", "2014-09-17 00:32:49.211146"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.212244"], ["updated_at", "2014-09-17 00:32:49.212244"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.213126"], ["updated_at", "2014-09-17 00:32:49.213126"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.214904"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:49.214904"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["body", "Something else"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-09-17 00:32:49.216389"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.3ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------- Commontator::Comment: test_0003_must know if it has been deleted ----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.218003"], ["updated_at", "2014-09-17 00:32:49.218003"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.219087"], ["updated_at", "2014-09-17 00:32:49.219087"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.220060"], ["updated_at", "2014-09-17 00:32:49.220060"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-09-17 00:32:49.220946') LIMIT 1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.222507"], ["updated_at", "2014-09-17 00:32:49.222507"]] SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "deleted_at", "editor_id", "editor_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.223062"], ["creator_id", 1], ["creator_type", "DummyUser"], ["deleted_at", "2014-09-17 00:32:49.220946"], ["editor_id", 2], ["editor_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:49.223062"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["updated_at", "2014-09-17 00:32:49.224621"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------- Commontator::Comment: test_0004_must make proper timestamps -----------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.226177"], ["updated_at", "2014-09-17 00:32:49.226177"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.227235"], ["updated_at", "2014-09-17 00:32:49.227235"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.228153"], ["updated_at", "2014-09-17 00:32:49.228153"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.229653"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:49.229653"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.231212"], ["updated_at", "2014-09-17 00:32:49.231212"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.3ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["body", "Something else"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-09-17 00:32:49.232848"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.3ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0001_won't subscribe unless authorized ---------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.235794"], ["updated_at", "2014-09-17 00:32:49.235794"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.236856"], ["updated_at", "2014-09-17 00:32:49.236856"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.237742"], ["updated_at", "2014-09-17 00:32:49.237742"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:49.243736"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:49.243736"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0002_must subscribe if authorized ----------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.248579"], ["updated_at", "2014-09-17 00:32:49.248579"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.249867"], ["updated_at", "2014-09-17 00:32:49.249867"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.250958"], ["updated_at", "2014-09-17 00:32:49.250958"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:49.255474"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:49.255474"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.4ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:49.261015"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:49.261015"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:49.265730"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:49.265730"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.4ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0003_won't unsubscribe unless authorized -----------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.269255"], ["updated_at", "2014-09-17 00:32:49.269255"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.271245"], ["updated_at", "2014-09-17 00:32:49.271245"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.273122"], ["updated_at", "2014-09-17 00:32:49.273122"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:49.276274"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:49.276274"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::SubscriptionsController: test_0004_must unsubscribe if authorized ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.285989"], ["updated_at", "2014-09-17 00:32:49.285989"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.287437"], ["updated_at", "2014-09-17 00:32:49.287437"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.288577"], ["updated_at", "2014-09-17 00:32:49.288577"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:49.291958"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:49.291958"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:49.298807"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:49.298807"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:49.303587"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:49.303587"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 3]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.5ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------- Commontator::Subscription: test_0001_must count unread comments ---------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.310245"], ["updated_at", "2014-09-17 00:32:49.310245"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.312246"], ["updated_at", "2014-09-17 00:32:49.312246"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.313726"], ["updated_at", "2014-09-17 00:32:49.313726"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:49.315981"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:49.315981"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-09-17 00:32:49.315981') [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.320560"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:49.320560"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-09-17 00:32:49.315981') [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:49.324232"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:49.324232"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-09-17 00:32:49.315981') [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-09-17 00:32:49.326781' WHERE "commontator_subscriptions"."id" = 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-09-17 00:32:49.326781') [["thread_id", 1]]  (0.5ms) rollback transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.332047"], ["updated_at", "2014-09-17 00:32:49.332047"]]  (0.6ms) commit transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::SharedHelper: test_0001_must show commontator thread -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.337605"], ["updated_at", "2014-09-17 00:32:49.337605"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.338838"], ["updated_at", "2014-09-17 00:32:49.338838"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 1]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/shared/_thread.html.erb (8.4ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction SQL (0.5ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.353840"], ["updated_at", "2014-09-17 00:32:49.353840"]]  (0.8ms) commit transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.357132"], ["updated_at", "2014-09-17 00:32:49.357132"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.359063"], ["updated_at", "2014-09-17 00:32:49.359063"]]  (0.5ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.360627"], ["updated_at", "2014-09-17 00:32:49.360627"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.363148"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:32:49.363148"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-09-17 00:32:49.364549"], ["closer_id", 2], ["closer_type", "DummyUser"], ["updated_at", "2014-09-17 00:32:49.365450"]]  (0.6ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 1 LIMIT 1 [["thread_id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 2], ["commontable_type", "DummyModel"]]  (0.1ms) begin transaction Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] SQL (0.2ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "commontable_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["commontable_id", nil], ["commontable_type", nil], ["updated_at", "2014-09-17 00:32:49.370002"]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.371383"], ["updated_at", "2014-09-17 00:32:49.371383"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]]  (0.7ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 1 LIMIT 1 [["thread_id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 2], ["commontable_type", "DummyModel"]] Commontator::Comment Exists (0.0ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 1 LIMIT 1 [["thread_id", 2]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.375654"], ["updated_at", "2014-09-17 00:32:49.375654"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.377381"], ["updated_at", "2014-09-17 00:32:49.377381"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 3], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.378871"], ["updated_at", "2014-09-17 00:32:49.378871"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 3 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 3], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 3 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 3) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:49.381691"], ["subscriber_id", 3], ["subscriber_type", "DummyUser"], ["thread_id", 3], ["updated_at", "2014-09-17 00:32:49.381691"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 3 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 3], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 3]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-09-17 00:32:49.381691') [["thread_id", 3]]  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 3 AND "commontator_comments"."thread_id" = 3 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.386366"], ["creator_id", 3], ["creator_type", "DummyUser"], ["thread_id", 3], ["updated_at", "2014-09-17 00:32:49.386366"]]  (0.5ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 3]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-09-17 00:32:49.381691') [["thread_id", 3]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 3 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 3], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction SQL (0.2ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-09-17 00:32:49.390712' WHERE "commontator_subscriptions"."id" = 1  (0.5ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 3]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-09-17 00:32:49.390712') [["thread_id", 3]]  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.395133"], ["updated_at", "2014-09-17 00:32:49.395133"]]  (0.5ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.397220"], ["updated_at", "2014-09-17 00:32:49.397220"]]  (0.5ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 4], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.398927"], ["updated_at", "2014-09-17 00:32:49.398927"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.400843"], ["updated_at", "2014-09-17 00:32:49.400843"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.402706"], ["updated_at", "2014-09-17 00:32:49.402706"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 5], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.404264"], ["updated_at", "2014-09-17 00:32:49.404264"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 5 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 5], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 5 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 5) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:49.407431"], ["subscriber_id", 5], ["subscriber_type", "DummyUser"], ["thread_id", 5], ["updated_at", "2014-09-17 00:32:49.407431"]]  (0.6ms) commit transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.409215"], ["updated_at", "2014-09-17 00:32:49.409215"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 5 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 6], ["subscriber_type", "DummyUser"]]  (0.1ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 5 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 6) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:49.419618"], ["subscriber_id", 6], ["subscriber_type", "DummyUser"], ["thread_id", 5], ["updated_at", "2014-09-17 00:32:49.419618"]]  (0.8ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 5]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 5]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 6]]  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.423994"], ["updated_at", "2014-09-17 00:32:49.423994"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.425775"], ["updated_at", "2014-09-17 00:32:49.425775"]]  (0.6ms) commit transaction  (0.1ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 6], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.427307"], ["updated_at", "2014-09-17 00:32:49.427307"]]  (0.7ms) commit transaction  (0.1ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 6 AND "commontator_threads"."id" != 6 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 6 [["closed_at", "2014-09-17 00:32:49.428693"], ["closer_id", 7], ["closer_type", "DummyUser"], ["updated_at", "2014-09-17 00:32:49.429577"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 6 AND "commontator_threads"."id" != 6 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 6 [["closed_at", nil], ["updated_at", "2014-09-17 00:32:49.431538"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.432959"], ["updated_at", "2014-09-17 00:32:49.432959"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.434637"], ["updated_at", "2014-09-17 00:32:49.434637"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 7], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.436137"], ["updated_at", "2014-09-17 00:32:49.436137"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 7 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 8], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.3ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 7 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 8) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:49.439370"], ["subscriber_id", 8], ["subscriber_type", "DummyUser"], ["thread_id", 7], ["updated_at", "2014-09-17 00:32:49.439370"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.441061"], ["updated_at", "2014-09-17 00:32:49.441061"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 7 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 9], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 7 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 9) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:49.443764"], ["subscriber_id", 9], ["subscriber_type", "DummyUser"], ["thread_id", 7], ["updated_at", "2014-09-17 00:32:49.443764"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 7 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 8], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 7]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 8]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 7 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 9], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 7]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.447919"], ["updated_at", "2014-09-17 00:32:49.447919"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.449550"], ["updated_at", "2014-09-17 00:32:49.449550"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 8], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.451094"], ["updated_at", "2014-09-17 00:32:49.451094"]]  (0.6ms) commit transaction  (0.1ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 10 AND "commontator_comments"."thread_id" = 8 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.453728"], ["creator_id", 10], ["creator_type", "DummyUser"], ["thread_id", 8], ["updated_at", "2014-09-17 00:32:49.453728"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 10 AND "commontator_comments"."thread_id" = 8 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:49.456124"], ["creator_id", 10], ["creator_type", "DummyUser"], ["thread_id", 8], ["updated_at", "2014-09-17 00:32:49.456124"]]  (0.6ms) commit transaction Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 8]] Commontator::Comment Load (0.2ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY created_at ASC [["thread_id", 8]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.458956"], ["updated_at", "2014-09-17 00:32:49.458956"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.460589"], ["updated_at", "2014-09-17 00:32:49.460589"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.462115"], ["updated_at", "2014-09-17 00:32:49.462115"]]  (0.6ms) commit transaction  (0.0ms) begin transaction DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", nil]] SQL (0.1ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 9 [["commontable_id", nil], ["updated_at", "2014-09-17 00:32:49.463993"]]  (0.4ms) commit transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) begin transaction -------------------------------------------------------------------------- Commontator::CommentsController: test_0001_won't get new unless authorized --------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.467516"], ["updated_at", "2014-09-17 00:32:49.467516"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.468630"], ["updated_at", "2014-09-17 00:32:49.468630"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.469552"], ["updated_at", "2014-09-17 00:32:49.469552"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.471169"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.471169"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------- Commontator::CommentsController: test_0002_must get new if authorized ---------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.477168"], ["updated_at", "2014-09-17 00:32:49.477168"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.478517"], ["updated_at", "2014-09-17 00:32:49.478517"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.480148"], ["updated_at", "2014-09-17 00:32:49.480148"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.482644"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.482644"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 1ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0003_won't create unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.492738"], ["updated_at", "2014-09-17 00:32:49.492738"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.494093"], ["updated_at", "2014-09-17 00:32:49.494093"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.495576"], ["updated_at", "2014-09-17 00:32:49.495576"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.498043"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.498043"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-09-17 00:32:49.502095"], ["updated_at", "2014-09-17 00:32:49.503002"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0004_must create if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.506939"], ["updated_at", "2014-09-17 00:32:49.506939"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.508067"], ["updated_at", "2014-09-17 00:32:49.508067"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.509441"], ["updated_at", "2014-09-17 00:32:49.509441"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.511443"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.511443"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:49.514879"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.514879"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Another thing"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Another thing' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Another thing"], ["created_at", "2014-09-17 00:32:49.519076"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.519076"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"And this too"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'And this too' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "And this too"], ["created_at", "2014-09-17 00:32:49.523490"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.523490"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.3ms)  (0.6ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0005_won't create if double posting -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.527132"], ["updated_at", "2014-09-17 00:32:49.527132"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.528439"], ["updated_at", "2014-09-17 00:32:49.528439"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.529579"], ["updated_at", "2014-09-17 00:32:49.529579"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.532031"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.532031"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:49.541305"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.541305"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------- Commontator::CommentsController: test_0006_won't edit unless authorized -----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.547552"], ["updated_at", "2014-09-17 00:32:49.547552"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.548686"], ["updated_at", "2014-09-17 00:32:49.548686"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.549619"], ["updated_at", "2014-09-17 00:32:49.549619"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.551144"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.551144"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.555819"], ["updated_at", "2014-09-17 00:32:49.555819"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:49.559682"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.559682"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------ Commontator::CommentsController: test_0007_must edit if authorized ------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.564818"], ["updated_at", "2014-09-17 00:32:49.564818"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.566534"], ["updated_at", "2014-09-17 00:32:49.566534"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.567937"], ["updated_at", "2014-09-17 00:32:49.567937"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.570162"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.570162"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.6ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0008_won't update unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.583580"], ["updated_at", "2014-09-17 00:32:49.583580"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.584689"], ["updated_at", "2014-09-17 00:32:49.584689"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.585622"], ["updated_at", "2014-09-17 00:32:49.585622"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.587708"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.587708"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.594928"], ["updated_at", "2014-09-17 00:32:49.594928"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:49.599141"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.599141"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.4ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0009_must update if authorized --------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.604684"], ["updated_at", "2014-09-17 00:32:49.604684"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.606763"], ["updated_at", "2014-09-17 00:32:49.606763"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.608256"], ["updated_at", "2014-09-17 00:32:49.608256"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.610523"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.610523"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["body", "Something else"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-09-17 00:32:49.616053"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 5ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------------- Commontator::CommentsController: test_0010_won't delete unless authorized and not deleted -----------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.628045"], ["updated_at", "2014-09-17 00:32:49.628045"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.629169"], ["updated_at", "2014-09-17 00:32:49.629169"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.630090"], ["updated_at", "2014-09-17 00:32:49.630090"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.631636"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.631636"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-09-17 00:32:49.636326') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-09-17 00:32:49.636326"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-09-17 00:32:49.637725"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 9ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:49.649229"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.649229"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-09-17 00:32:49.650806"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.5ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------------------ Commontator::CommentsController: test_0011_must delete if authorized and not deleted ------------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.656207"], ["updated_at", "2014-09-17 00:32:49.656207"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.658091"], ["updated_at", "2014-09-17 00:32:49.658091"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.659660"], ["updated_at", "2014-09-17 00:32:49.659660"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.662083"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.662083"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-09-17 00:32:49.666706') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-09-17 00:32:49.666706"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-09-17 00:32:49.667851"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 5ms (ActiveRecord: 0.5ms)  (0.1ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.669679"], ["updated_at", "2014-09-17 00:32:49.669679"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:49.671103"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.671103"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-09-17 00:32:49.672728"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-09-17 00:32:49.674878') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-09-17 00:32:49.674878"], ["editor_id", 13], ["updated_at", "2014-09-17 00:32:49.675807"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 12], ["updated_at", "2014-09-17 00:32:49.677941"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-09-17 00:32:49.679784') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-09-17 00:32:49.679784"], ["editor_id", 13], ["updated_at", "2014-09-17 00:32:49.680703"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.6ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------------------- Commontator::CommentsController: test_0012_won't undelete unless authorized and deleted ---------------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.683902"], ["updated_at", "2014-09-17 00:32:49.683902"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.685778"], ["updated_at", "2014-09-17 00:32:49.685778"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.687315"], ["updated_at", "2014-09-17 00:32:49.687315"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.689695"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.689695"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-09-17 00:32:49.690678') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-09-17 00:32:49.690678"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-09-17 00:32:49.691847"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-09-17 00:32:49.699833"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.704419"], ["updated_at", "2014-09-17 00:32:49.704419"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-09-17 00:32:49.705091') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-09-17 00:32:49.705091"], ["editor_id", 13], ["updated_at", "2014-09-17 00:32:49.706167"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 13]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:49.710245"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.710245"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 12], ["updated_at", "2014-09-17 00:32:49.712098"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-09-17 00:32:49.712567') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-09-17 00:32:49.712567"], ["updated_at", "2014-09-17 00:32:49.713308"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.5ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------------------------- Commontator::CommentsController: test_0013_must undelete if authorized and deleted ----------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.718931"], ["updated_at", "2014-09-17 00:32:49.718931"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.720815"], ["updated_at", "2014-09-17 00:32:49.720815"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.722390"], ["updated_at", "2014-09-17 00:32:49.722390"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.724758"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.724758"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-09-17 00:32:49.725678') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-09-17 00:32:49.725678"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-09-17 00:32:49.726813"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-09-17 00:32:49.732296"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 5ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.733836"], ["updated_at", "2014-09-17 00:32:49.733836"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:49.735239"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.735239"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-09-17 00:32:49.735872') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-09-17 00:32:49.735872"], ["updated_at", "2014-09-17 00:32:49.736706"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 13], ["updated_at", "2014-09-17 00:32:49.739570"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-09-17 00:32:49.740709') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-09-17 00:32:49.740709"], ["editor_id", 12], ["updated_at", "2014-09-17 00:32:49.741516"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 13], ["updated_at", "2014-09-17 00:32:49.744330"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0014_won't upvote unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.747034"], ["updated_at", "2014-09-17 00:32:49.747034"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.748144"], ["updated_at", "2014-09-17 00:32:49.748144"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.749076"], ["updated_at", "2014-09-17 00:32:49.749076"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.750670"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.750670"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.760586"], ["updated_at", "2014-09-17 00:32:49.760586"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0015_must upvote if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.766049"], ["updated_at", "2014-09-17 00:32:49.766049"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.767195"], ["updated_at", "2014-09-17 00:32:49.767195"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.768129"], ["updated_at", "2014-09-17 00:32:49.768129"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.769764"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.769764"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.770648"], ["updated_at", "2014-09-17 00:32:49.770648"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:49.778730"], ["updated_at", "2014-09-17 00:32:49.778730"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 10ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.2ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 7ms (ActiveRecord: 0.8ms)  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-09-17 00:32:49.794376"], ["vote_flag", "f"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-09-17 00:32:49.801180"], ["vote_flag", "t"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------- Commontator::CommentsController: test_0016_won't downvote unless authorized ---------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.807407"], ["updated_at", "2014-09-17 00:32:49.807407"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.809506"], ["updated_at", "2014-09-17 00:32:49.809506"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.810985"], ["updated_at", "2014-09-17 00:32:49.810985"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.813555"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.813555"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.821788"], ["updated_at", "2014-09-17 00:32:49.821788"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------- Commontator::CommentsController: test_0017_must downvote if authorized ----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.827571"], ["updated_at", "2014-09-17 00:32:49.827571"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.829457"], ["updated_at", "2014-09-17 00:32:49.829457"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.831116"], ["updated_at", "2014-09-17 00:32:49.831116"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.833658"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.833658"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.834941"], ["updated_at", "2014-09-17 00:32:49.834941"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:49.840564"], ["updated_at", "2014-09-17 00:32:49.840564"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "f"], ["vote_weight", 1], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 7ms (ActiveRecord: 0.7ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 11ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-09-17 00:32:49.860135"], ["vote_flag", "t"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-09-17 00:32:49.866004"], ["vote_flag", "f"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0018_won't unvote unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.871796"], ["updated_at", "2014-09-17 00:32:49.871796"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.873116"], ["updated_at", "2014-09-17 00:32:49.873116"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.874219"], ["updated_at", "2014-09-17 00:32:49.874219"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.875975"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.875975"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:49.878252"], ["updated_at", "2014-09-17 00:32:49.878252"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 12], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.887244"], ["updated_at", "2014-09-17 00:32:49.887244"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0019_must unvote if authorized --------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.893805"], ["updated_at", "2014-09-17 00:32:49.893805"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.895670"], ["updated_at", "2014-09-17 00:32:49.895670"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.897212"], ["updated_at", "2014-09-17 00:32:49.897212"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.899680"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.899680"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.900911"], ["updated_at", "2014-09-17 00:32:49.900911"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:49.903382"], ["updated_at", "2014-09-17 00:32:49.903382"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 7ms (ActiveRecord: 0.7ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:49.920743"], ["updated_at", "2014-09-17 00:32:49.920743"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "f"], ["vote_weight", 1], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 2]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 8ms (ActiveRecord: 0.8ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.6ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------------ Commontator::CommentsController: test_0020_won't send mail if recipients empty ------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.936874"], ["updated_at", "2014-09-17 00:32:49.936874"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.938880"], ["updated_at", "2014-09-17 00:32:49.938880"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.940419"], ["updated_at", "2014-09-17 00:32:49.940419"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.942928"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.942928"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.944189"], ["updated_at", "2014-09-17 00:32:49.944189"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:49.948507"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.948507"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.4ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------------- Commontator::CommentsController: test_0021_must send mail if recipients not empty ---------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.952230"], ["updated_at", "2014-09-17 00:32:49.952230"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.953962"], ["updated_at", "2014-09-17 00:32:49.953962"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:32:49.955391"], ["updated_at", "2014-09-17 00:32:49.955391"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:32:49.957706"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.957706"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:32:49.958924"], ["updated_at", "2014-09-17 00:32:49.958924"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 13], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 13) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:32:49.961792"], ["subscriber_id", 13], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.961792"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:32:49.966284"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:32:49.966284"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 13]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.5ms) rollback transaction  (1.8ms) CREATE TABLE "commontator_comments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "creator_type" varchar(255), "creator_id" integer, "editor_type" varchar(255), "editor_id" integer, "thread_id" integer NOT NULL, "body" text NOT NULL, "deleted_at" datetime, "cached_votes_up" integer DEFAULT 0, "cached_votes_down" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime)   (0.1ms) select sqlite_version(*)  (0.8ms) CREATE INDEX "index_commontator_comments_on_cached_votes_down" ON "commontator_comments" ("cached_votes_down")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'  (0.7ms) CREATE INDEX "index_commontator_comments_on_cached_votes_up" ON "commontator_comments" ("cached_votes_up")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_comments_on_c_id_and_c_type_and_t_id" ON "commontator_comments" ("creator_id", "creator_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_comments_on_thread_id_and_created_at" ON "commontator_comments" ("thread_id", "created_at")  (0.8ms) CREATE TABLE "commontator_subscriptions" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "subscriber_type" varchar(255) NOT NULL, "subscriber_id" integer NOT NULL, "thread_id" integer NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE UNIQUE INDEX "index_commontator_subscriptions_on_s_id_and_s_type_and_t_id" ON "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index'   (1.0ms) CREATE INDEX "index_commontator_subscriptions_on_thread_id" ON "commontator_subscriptions" ("thread_id")  (0.8ms) CREATE TABLE "commontator_threads" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "commontable_type" varchar(255), "commontable_id" integer, "closed_at" datetime, "closer_type" varchar(255), "closer_id" integer, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE UNIQUE INDEX "index_commontator_threads_on_c_id_and_c_type" ON "commontator_threads" ("commontable_id", "commontable_type")  (0.8ms) CREATE TABLE "dummy_models" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE TABLE "dummy_users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)  (0.8ms) CREATE TABLE "votes" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "votable_id" integer, "votable_type" varchar(255), "voter_id" integer, "voter_type" varchar(255), "vote_flag" boolean, "vote_scope" varchar(255), "vote_weight" integer, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE INDEX "index_votes_on_votable_id_and_votable_type_and_vote_scope" ON "votes" ("votable_id", "votable_type", "vote_scope")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index'   (0.8ms) CREATE INDEX "index_votes_on_voter_id_and_voter_type_and_vote_scope" ON "votes" ("voter_id", "voter_type", "vote_scope")  (0.8ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)   (0.8ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.1ms) SELECT version FROM "schema_migrations"  (0.6ms) INSERT INTO "schema_migrations" (version) VALUES ('3')  (0.6ms) INSERT INTO "schema_migrations" (version) VALUES ('1')  (0.6ms) INSERT INTO "schema_migrations" (version) VALUES ('2')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.0ms) begin transaction SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:28.996301"], ["updated_at", "2014-09-17 00:34:28.996301"]]  (1.5ms) commit transaction  (0.1ms) begin transaction ------------------------------------------------------------------------------- Commontator::Comment: test_0001_must be votable if acts_as_votable is installed -------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.003755"], ["updated_at", "2014-09-17 00:34:29.003755"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.006571"], ["updated_at", "2014-09-17 00:34:29.006571"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.007698"], ["updated_at", "2014-09-17 00:34:29.007698"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::Comment: test_0002_must know if it has been modified -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.017588"], ["updated_at", "2014-09-17 00:34:29.017588"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.018985"], ["updated_at", "2014-09-17 00:34:29.018985"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.019900"], ["updated_at", "2014-09-17 00:34:29.019900"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.027353"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.027353"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["body", "Something else"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-09-17 00:34:29.029350"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------- Commontator::Comment: test_0003_must know if it has been deleted ----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.031333"], ["updated_at", "2014-09-17 00:34:29.031333"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.032362"], ["updated_at", "2014-09-17 00:34:29.032362"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.033251"], ["updated_at", "2014-09-17 00:34:29.033251"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-09-17 00:34:29.034171') LIMIT 1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.035166"], ["updated_at", "2014-09-17 00:34:29.035166"]] SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "deleted_at", "editor_id", "editor_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.035653"], ["creator_id", 1], ["creator_type", "DummyUser"], ["deleted_at", "2014-09-17 00:34:29.034171"], ["editor_id", 2], ["editor_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.035653"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["updated_at", "2014-09-17 00:34:29.037213"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.3ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------- Commontator::Comment: test_0004_must make proper timestamps -----------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.038609"], ["updated_at", "2014-09-17 00:34:29.038609"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.039614"], ["updated_at", "2014-09-17 00:34:29.039614"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.040581"], ["updated_at", "2014-09-17 00:34:29.040581"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.042341"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.042341"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.043952"], ["updated_at", "2014-09-17 00:34:29.043952"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["body", "Something else"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-09-17 00:34:29.045269"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------------- Commontator::CommentsController: test_0001_won't get new unless authorized --------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.050397"], ["updated_at", "2014-09-17 00:34:29.050397"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.051518"], ["updated_at", "2014-09-17 00:34:29.051518"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.052540"], ["updated_at", "2014-09-17 00:34:29.052540"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.054151"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.054151"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------- Commontator::CommentsController: test_0002_must get new if authorized ---------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.062703"], ["updated_at", "2014-09-17 00:34:29.062703"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.063946"], ["updated_at", "2014-09-17 00:34:29.063946"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.064901"], ["updated_at", "2014-09-17 00:34:29.064901"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.066461"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.066461"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 1ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0003_won't create unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.075270"], ["updated_at", "2014-09-17 00:34:29.075270"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.077225"], ["updated_at", "2014-09-17 00:34:29.077225"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.078821"], ["updated_at", "2014-09-17 00:34:29.078821"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.081329"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.081329"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-09-17 00:34:29.085421"], ["updated_at", "2014-09-17 00:34:29.086527"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0004_must create if authorized --------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.090928"], ["updated_at", "2014-09-17 00:34:29.090928"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.092791"], ["updated_at", "2014-09-17 00:34:29.092791"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.094311"], ["updated_at", "2014-09-17 00:34:29.094311"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.096766"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.096766"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:34:29.101119"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.101119"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 8ms (ActiveRecord: 0.5ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Another thing"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Another thing' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Another thing"], ["created_at", "2014-09-17 00:34:29.109960"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.109960"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"And this too"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'And this too' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "And this too"], ["created_at", "2014-09-17 00:34:29.113814"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.113814"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0005_won't create if double posting -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.117182"], ["updated_at", "2014-09-17 00:34:29.117182"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.119095"], ["updated_at", "2014-09-17 00:34:29.119095"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.120720"], ["updated_at", "2014-09-17 00:34:29.120720"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.123134"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.123134"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:34:29.131576"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.131576"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------------- Commontator::CommentsController: test_0006_won't edit unless authorized -----------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.138354"], ["updated_at", "2014-09-17 00:34:29.138354"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.140293"], ["updated_at", "2014-09-17 00:34:29.140293"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.141809"], ["updated_at", "2014-09-17 00:34:29.141809"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.144165"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.144165"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 4ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.150537"], ["updated_at", "2014-09-17 00:34:29.150537"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:34:29.154175"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.154175"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------ Commontator::CommentsController: test_0007_must edit if authorized ------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.159450"], ["updated_at", "2014-09-17 00:34:29.159450"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.161434"], ["updated_at", "2014-09-17 00:34:29.161434"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.162971"], ["updated_at", "2014-09-17 00:34:29.162971"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.171541"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.171541"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.6ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0008_won't update unless authorized -------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.183949"], ["updated_at", "2014-09-17 00:34:29.183949"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.185876"], ["updated_at", "2014-09-17 00:34:29.185876"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.187407"], ["updated_at", "2014-09-17 00:34:29.187407"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.189865"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.189865"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.196756"], ["updated_at", "2014-09-17 00:34:29.196756"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:34:29.201151"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.201151"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 4ms (ActiveRecord: 0.3ms) Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.5ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0009_must update if authorized --------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.209813"], ["updated_at", "2014-09-17 00:34:29.209813"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.211368"], ["updated_at", "2014-09-17 00:34:29.211368"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.212644"], ["updated_at", "2014-09-17 00:34:29.212644"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.214645"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.214645"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["body", "Something else"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-09-17 00:34:29.219532"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------------------------------- Commontator::CommentsController: test_0010_won't delete unless authorized and not deleted -----------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.230424"], ["updated_at", "2014-09-17 00:34:29.230424"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.231507"], ["updated_at", "2014-09-17 00:34:29.231507"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.232422"], ["updated_at", "2014-09-17 00:34:29.232422"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.233903"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.233903"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-09-17 00:34:29.238365') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-09-17 00:34:29.238365"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-09-17 00:34:29.239694"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:34:29.245120"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.245120"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["updated_at", "2014-09-17 00:34:29.246567"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.5ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------------------ Commontator::CommentsController: test_0011_must delete if authorized and not deleted ------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.251777"], ["updated_at", "2014-09-17 00:34:29.251777"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.253869"], ["updated_at", "2014-09-17 00:34:29.253869"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.255185"], ["updated_at", "2014-09-17 00:34:29.255185"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.257275"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.257275"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-09-17 00:34:29.261371') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-09-17 00:34:29.261371"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-09-17 00:34:29.262270"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.263977"], ["updated_at", "2014-09-17 00:34:29.263977"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:34:29.265372"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.265372"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["updated_at", "2014-09-17 00:34:29.266766"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-09-17 00:34:29.268672') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-09-17 00:34:29.268672"], ["editor_id", 2], ["updated_at", "2014-09-17 00:34:29.269527"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["editor_id", 1], ["updated_at", "2014-09-17 00:34:29.271514"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-09-17 00:34:29.273405') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-09-17 00:34:29.273405"], ["editor_id", 2], ["updated_at", "2014-09-17 00:34:29.274260"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------------------- Commontator::CommentsController: test_0012_won't undelete unless authorized and deleted ---------------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.277315"], ["updated_at", "2014-09-17 00:34:29.277315"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.279219"], ["updated_at", "2014-09-17 00:34:29.279219"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.280763"], ["updated_at", "2014-09-17 00:34:29.280763"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.283048"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.283048"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-09-17 00:34:29.284024') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-09-17 00:34:29.284024"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-09-17 00:34:29.285246"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["updated_at", "2014-09-17 00:34:29.292863"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.297082"], ["updated_at", "2014-09-17 00:34:29.297082"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-09-17 00:34:29.297648') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-09-17 00:34:29.297648"], ["editor_id", 2], ["updated_at", "2014-09-17 00:34:29.298490"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:34:29.302689"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.302689"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["editor_id", 1], ["updated_at", "2014-09-17 00:34:29.304709"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-09-17 00:34:29.305220') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-09-17 00:34:29.305220"], ["updated_at", "2014-09-17 00:34:29.305994"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.6ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------------------------- Commontator::CommentsController: test_0013_must undelete if authorized and deleted ----------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.312120"], ["updated_at", "2014-09-17 00:34:29.312120"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.314071"], ["updated_at", "2014-09-17 00:34:29.314071"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.315592"], ["updated_at", "2014-09-17 00:34:29.315592"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.317978"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.317978"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-09-17 00:34:29.318882') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-09-17 00:34:29.318882"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-09-17 00:34:29.319996"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["updated_at", "2014-09-17 00:34:29.325529"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.5ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.327286"], ["updated_at", "2014-09-17 00:34:29.327286"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:34:29.328721"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.328721"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-09-17 00:34:29.329367') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-09-17 00:34:29.329367"], ["updated_at", "2014-09-17 00:34:29.330153"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["editor_id", 2], ["updated_at", "2014-09-17 00:34:29.333411"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-09-17 00:34:29.334650') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-09-17 00:34:29.334650"], ["editor_id", 1], ["updated_at", "2014-09-17 00:34:29.335480"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["editor_id", 2], ["updated_at", "2014-09-17 00:34:29.338597"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.6ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0014_won't upvote unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.341467"], ["updated_at", "2014-09-17 00:34:29.341467"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.343263"], ["updated_at", "2014-09-17 00:34:29.343263"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.344885"], ["updated_at", "2014-09-17 00:34:29.344885"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.347243"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.347243"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.359724"], ["updated_at", "2014-09-17 00:34:29.359724"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.6ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0015_must upvote if authorized --------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.366365"], ["updated_at", "2014-09-17 00:34:29.366365"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.367882"], ["updated_at", "2014-09-17 00:34:29.367882"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.369427"], ["updated_at", "2014-09-17 00:34:29.369427"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.371954"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.371954"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.373218"], ["updated_at", "2014-09-17 00:34:29.373218"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:34:29.387715"], ["updated_at", "2014-09-17 00:34:29.387715"], ["votable_id", 1], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 16ms (ActiveRecord: 0.7ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-09-17 00:34:29.401969"], ["vote_flag", "f"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-09-17 00:34:29.408002"], ["vote_flag", "t"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------- Commontator::CommentsController: test_0016_won't downvote unless authorized ---------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.413538"], ["updated_at", "2014-09-17 00:34:29.413538"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.414680"], ["updated_at", "2014-09-17 00:34:29.414680"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.415648"], ["updated_at", "2014-09-17 00:34:29.415648"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.417321"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.417321"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.424421"], ["updated_at", "2014-09-17 00:34:29.424421"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------------- Commontator::CommentsController: test_0017_must downvote if authorized ----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.429877"], ["updated_at", "2014-09-17 00:34:29.429877"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.431003"], ["updated_at", "2014-09-17 00:34:29.431003"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.431885"], ["updated_at", "2014-09-17 00:34:29.431885"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.433398"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.433398"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.434266"], ["updated_at", "2014-09-17 00:34:29.434266"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:34:29.438537"], ["updated_at", "2014-09-17 00:34:29.438537"], ["votable_id", 1], ["votable_type", "Commontator::Comment"], ["vote_flag", "f"], ["vote_weight", 1], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.4ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-09-17 00:34:29.451688"], ["vote_flag", "t"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-09-17 00:34:29.458052"], ["vote_flag", "f"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.7ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0018_won't unvote unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.463957"], ["updated_at", "2014-09-17 00:34:29.463957"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.465356"], ["updated_at", "2014-09-17 00:34:29.465356"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.466486"], ["updated_at", "2014-09-17 00:34:29.466486"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.468944"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.468944"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 1 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:34:29.471872"], ["updated_at", "2014-09-17 00:34:29.471872"], ["votable_id", 1], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 1], ["voter_type", "DummyUser"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.481342"], ["updated_at", "2014-09-17 00:34:29.481342"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.6ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0019_must unvote if authorized --------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.487754"], ["updated_at", "2014-09-17 00:34:29.487754"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.489659"], ["updated_at", "2014-09-17 00:34:29.489659"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.491174"], ["updated_at", "2014-09-17 00:34:29.491174"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.493649"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.493649"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.494920"], ["updated_at", "2014-09-17 00:34:29.494920"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:34:29.497412"], ["updated_at", "2014-09-17 00:34:29.497412"], ["votable_id", 1], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 7ms (ActiveRecord: 0.7ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:34:29.514957"], ["updated_at", "2014-09-17 00:34:29.514957"], ["votable_id", 1], ["votable_type", "Commontator::Comment"], ["vote_flag", "f"], ["vote_weight", 1], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::CommentsController: test_0020_won't send mail if recipients empty ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.525892"], ["updated_at", "2014-09-17 00:34:29.525892"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.527061"], ["updated_at", "2014-09-17 00:34:29.527061"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.527981"], ["updated_at", "2014-09-17 00:34:29.527981"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.529567"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.529567"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.530519"], ["updated_at", "2014-09-17 00:34:29.530519"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:34:29.533875"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.533875"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.4ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------- Commontator::CommentsController: test_0021_must send mail if recipients not empty ---------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.537405"], ["updated_at", "2014-09-17 00:34:29.537405"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.538496"], ["updated_at", "2014-09-17 00:34:29.538496"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.539441"], ["updated_at", "2014-09-17 00:34:29.539441"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.541372"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.541372"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.542283"], ["updated_at", "2014-09-17 00:34:29.542283"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:34:29.547999"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.547999"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:34:29.551789"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.551789"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.4ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.556440"], ["updated_at", "2014-09-17 00:34:29.556440"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.558071"], ["updated_at", "2014-09-17 00:34:29.558071"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.559632"], ["updated_at", "2014-09-17 00:34:29.559632"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:34:29.562832"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.562832"]]  (1.2ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.564945"], ["updated_at", "2014-09-17 00:34:29.564945"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:34:29.567674"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-09-17 00:34:29.567674"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.571138"], ["updated_at", "2014-09-17 00:34:29.571138"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.572973"], ["updated_at", "2014-09-17 00:34:29.572973"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 3], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.574546"], ["updated_at", "2014-09-17 00:34:29.574546"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 3 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.577275"], ["creator_id", 3], ["creator_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-09-17 00:34:29.577275"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 3 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 2 [["closed_at", "2014-09-17 00:34:29.578770"], ["closer_id", 3], ["closer_type", "DummyUser"], ["updated_at", "2014-09-17 00:34:29.579542"]]  (0.6ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 1 LIMIT 1 [["thread_id", 2]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 3], ["commontable_type", "DummyModel"]]  (0.0ms) begin transaction Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] SQL (0.2ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "commontable_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 2 [["commontable_id", nil], ["commontable_type", nil], ["updated_at", "2014-09-17 00:34:29.584198"]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 3 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 3], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.585268"], ["updated_at", "2014-09-17 00:34:29.585268"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 2]]  (0.7ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 1 LIMIT 1 [["thread_id", 2]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 3], ["commontable_type", "DummyModel"]] Commontator::Comment Exists (0.0ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 1 LIMIT 1 [["thread_id", 3]]  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.595185"], ["updated_at", "2014-09-17 00:34:29.595185"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.596962"], ["updated_at", "2014-09-17 00:34:29.596962"]]  (0.8ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 4], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.598596"], ["updated_at", "2014-09-17 00:34:29.598596"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 4 AND "commontator_threads"."id" != 4 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 4 [["closed_at", "2014-09-17 00:34:29.599832"], ["closer_id", 4], ["closer_type", "DummyUser"], ["updated_at", "2014-09-17 00:34:29.600586"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 4 AND "commontator_threads"."id" != 4 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 4 [["closed_at", nil], ["updated_at", "2014-09-17 00:34:29.602805"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.604285"], ["updated_at", "2014-09-17 00:34:29.604285"]]  (3.9ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.609401"], ["updated_at", "2014-09-17 00:34:29.609401"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 5], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.611076"], ["updated_at", "2014-09-17 00:34:29.611076"]]  (0.6ms) commit transaction  (0.0ms) begin transaction DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", nil]] SQL (0.2ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 5 [["commontable_id", nil], ["updated_at", "2014-09-17 00:34:29.613044"]]  (0.6ms) commit transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.615025"], ["updated_at", "2014-09-17 00:34:29.615025"]]  (0.5ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.616610"], ["updated_at", "2014-09-17 00:34:29.616610"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 6], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.618196"], ["updated_at", "2014-09-17 00:34:29.618196"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.619782"], ["updated_at", "2014-09-17 00:34:29.619782"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.621373"], ["updated_at", "2014-09-17 00:34:29.621373"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 7], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.622795"], ["updated_at", "2014-09-17 00:34:29.622795"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 7 AND "commontator_comments"."thread_id" = 7 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.625354"], ["creator_id", 7], ["creator_type", "DummyUser"], ["thread_id", 7], ["updated_at", "2014-09-17 00:34:29.625354"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 7 AND "commontator_comments"."thread_id" = 7 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:34:29.627619"], ["creator_id", 7], ["creator_type", "DummyUser"], ["thread_id", 7], ["updated_at", "2014-09-17 00:34:29.627619"]]  (0.7ms) commit transaction Commontator::Comment Load (0.2ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 7]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY created_at ASC [["thread_id", 7]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.630497"], ["updated_at", "2014-09-17 00:34:29.630497"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.632158"], ["updated_at", "2014-09-17 00:34:29.632158"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 8], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.633622"], ["updated_at", "2014-09-17 00:34:29.633622"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.2ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 8 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 8], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 8 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 8) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:34:29.636521"], ["subscriber_id", 8], ["subscriber_type", "DummyUser"], ["thread_id", 8], ["updated_at", "2014-09-17 00:34:29.636521"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 8 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 8], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 8]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 8]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-09-17 00:34:29.636521') [["thread_id", 8]]  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 8 AND "commontator_comments"."thread_id" = 8 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.641333"], ["creator_id", 8], ["creator_type", "DummyUser"], ["thread_id", 8], ["updated_at", "2014-09-17 00:34:29.641333"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 8]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 8]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-09-17 00:34:29.636521') [["thread_id", 8]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 8 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 8], ["subscriber_type", "DummyUser"]]  (0.1ms) begin transaction SQL (0.2ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-09-17 00:34:29.645499' WHERE "commontator_subscriptions"."id" = 3  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 8]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 8]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-09-17 00:34:29.645499') [["thread_id", 8]]  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.650234"], ["updated_at", "2014-09-17 00:34:29.650234"]]  (0.6ms) commit transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.652584"], ["updated_at", "2014-09-17 00:34:29.652584"]]  (0.4ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.654174"], ["updated_at", "2014-09-17 00:34:29.654174"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.2ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 9 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 9], ["subscriber_type", "DummyUser"]]  (0.1ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 9 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 9) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:34:29.657509"], ["subscriber_id", 9], ["subscriber_type", "DummyUser"], ["thread_id", 9], ["updated_at", "2014-09-17 00:34:29.657509"]]  (0.5ms) commit transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.659081"], ["updated_at", "2014-09-17 00:34:29.659081"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 9 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 10], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 9 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 10) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:34:29.662308"], ["subscriber_id", 10], ["subscriber_type", "DummyUser"], ["thread_id", 9], ["updated_at", "2014-09-17 00:34:29.662308"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 9 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 9], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 9 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 10], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::ApplicationHelper: test_0001_must print javascript proc --------------------------------------------------------------------  (0.0ms) rollback transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.670630"], ["updated_at", "2014-09-17 00:34:29.670630"]]  (0.7ms) commit transaction  (0.0ms) begin transaction ------------------------------------------------------------------------ Commontator::SubscriptionsMailer: test_0001_must create deliverable mail ------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.675297"], ["updated_at", "2014-09-17 00:34:29.675297"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.676574"], ["updated_at", "2014-09-17 00:34:29.676574"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.677563"], ["updated_at", "2014-09-17 00:34:29.677563"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.678422"], ["updated_at", "2014-09-17 00:34:29.678422"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:34:29.680730"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:34:29.680730"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 13], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 13) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:34:29.682628"], ["subscriber_id", 13], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:34:29.682628"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.684231"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:34:29.684231"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 13]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/comments/_body.html.erb (3.5ms) Commontator::SubscriptionsMailer#comment_created: processed outbound mail in 20.6ms Sent mail to Undisclosed Recipients (5.2ms) Date: Tue, 16 Sep 2014 19:34:29 -0500 From: no-reply@dummy.com to: Undisclosed Recipients Message-ID: <5418d715ad7f4_c8e3fdec502dbe88253e@Dantes-MacBook-Pro.local.mail> Subject: Dummy User #12 posted a comment on DummyModel #10 Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit

Dummy User #12 commented on DummyModel #10:

Something

Click here to view all comments on DummyModel #10.

 (0.6ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0001_won't subscribe unless authorized ---------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.720243"], ["updated_at", "2014-09-17 00:34:29.720243"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.722279"], ["updated_at", "2014-09-17 00:34:29.722279"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.723744"], ["updated_at", "2014-09-17 00:34:29.723744"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:34:29.731241"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:34:29.731241"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0002_must subscribe if authorized ----------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.736382"], ["updated_at", "2014-09-17 00:34:29.736382"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.738295"], ["updated_at", "2014-09-17 00:34:29.738295"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.739859"], ["updated_at", "2014-09-17 00:34:29.739859"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:34:29.744961"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:34:29.744961"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 5ms (ActiveRecord: 0.4ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 6]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:34:29.751114"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:34:29.751114"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.4ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 7]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:34:29.756623"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:34:29.756623"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.6ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0003_won't unsubscribe unless authorized -----------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.760715"], ["updated_at", "2014-09-17 00:34:29.760715"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.762712"], ["updated_at", "2014-09-17 00:34:29.762712"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.764251"], ["updated_at", "2014-09-17 00:34:29.764251"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:34:29.767304"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:34:29.767304"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 6]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::SubscriptionsController: test_0004_must unsubscribe if authorized ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.776457"], ["updated_at", "2014-09-17 00:34:29.776457"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.777549"], ["updated_at", "2014-09-17 00:34:29.777549"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.778475"], ["updated_at", "2014-09-17 00:34:29.778475"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:34:29.780438"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:34:29.780438"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 6]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:34:29.785785"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:34:29.785785"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 7]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:34:29.790476"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:34:29.790476"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 8]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.5ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::SharedHelper: test_0001_must show commontator thread -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.799065"], ["updated_at", "2014-09-17 00:34:29.799065"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.800224"], ["updated_at", "2014-09-17 00:34:29.800224"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 10]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/shared/_thread.html.erb (13.3ms)  (0.6ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------- Commontator::Subscription: test_0001_must count unread comments ---------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.821149"], ["updated_at", "2014-09-17 00:34:29.821149"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.823195"], ["updated_at", "2014-09-17 00:34:29.823195"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.824723"], ["updated_at", "2014-09-17 00:34:29.824723"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-09-17 00:34:29.826854"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:34:29.826854"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-09-17 00:34:29.826854') [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-09-17 00:34:29.830049"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:34:29.830049"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-09-17 00:34:29.826854') [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-09-17 00:34:29.833864"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-09-17 00:34:29.833864"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-09-17 00:34:29.826854') [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-09-17 00:34:29.836879' WHERE "commontator_subscriptions"."id" = 6  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-09-17 00:34:29.836879') [["thread_id", 10]]  (0.6ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------------- Commontator::ThreadsController: test_0001_won't show unless authorized ----------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.842456"], ["updated_at", "2014-09-17 00:34:29.842456"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.844384"], ["updated_at", "2014-09-17 00:34:29.844384"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.845849"], ["updated_at", "2014-09-17 00:34:29.845849"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------- Commontator::ThreadsController: test_0002_must show if authorized -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.854415"], ["updated_at", "2014-09-17 00:34:29.854415"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.855909"], ["updated_at", "2014-09-17 00:34:29.855909"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.857133"], ["updated_at", "2014-09-17 00:34:29.857133"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 10], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 10], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 10], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------------------- Commontator::ThreadsController: test_0003_won't close unless authorized and open --------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.868647"], ["updated_at", "2014-09-17 00:34:29.868647"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.869868"], ["updated_at", "2014-09-17 00:34:29.869868"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.870840"], ["updated_at", "2014-09-17 00:34:29.870840"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-09-17 00:34:29.875677"], ["updated_at", "2014-09-17 00:34:29.876410"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------- Commontator::ThreadsController: test_0004_must close if authorized and open ---------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.881000"], ["updated_at", "2014-09-17 00:34:29.881000"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.882977"], ["updated_at", "2014-09-17 00:34:29.882977"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.884467"], ["updated_at", "2014-09-17 00:34:29.884467"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-09-17 00:34:29.887445"], ["closer_id", 12], ["closer_type", "DummyUser"], ["updated_at", "2014-09-17 00:34:29.888467"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", nil], ["updated_at", "2014-09-17 00:34:29.891151"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-09-17 00:34:29.893359"], ["updated_at", "2014-09-17 00:34:29.894202"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------- Commontator::ThreadsController: test_0005_won't reopen unless authorized and closed -----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.896900"], ["updated_at", "2014-09-17 00:34:29.896900"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.897965"], ["updated_at", "2014-09-17 00:34:29.897965"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.898863"], ["updated_at", "2014-09-17 00:34:29.898863"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-09-17 00:34:29.899420"], ["updated_at", "2014-09-17 00:34:29.900116"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", nil], ["updated_at", "2014-09-17 00:34:29.905698"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.8ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::ThreadsController: test_0006_must reopen if authorized and closed ------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.909765"], ["updated_at", "2014-09-17 00:34:29.909765"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-09-17 00:34:29.910878"], ["updated_at", "2014-09-17 00:34:29.910878"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-09-17 00:34:29.911813"], ["updated_at", "2014-09-17 00:34:29.911813"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-09-17 00:34:29.912381"], ["updated_at", "2014-09-17 00:34:29.913151"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", nil], ["updated_at", "2014-09-17 00:34:29.915877"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-09-17 00:34:29.917207"], ["updated_at", "2014-09-17 00:34:29.917800"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", nil], ["updated_at", "2014-09-17 00:34:29.920983"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (1.2ms) CREATE TABLE "commontator_comments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "creator_type" varchar(255), "creator_id" integer, "editor_type" varchar(255), "editor_id" integer, "thread_id" integer NOT NULL, "body" text NOT NULL, "deleted_at" datetime, "cached_votes_up" integer DEFAULT 0, "cached_votes_down" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime)   (0.1ms) select sqlite_version(*)  (0.8ms) CREATE INDEX "index_commontator_comments_on_cached_votes_down" ON "commontator_comments" ("cached_votes_down")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'  (0.7ms) CREATE INDEX "index_commontator_comments_on_cached_votes_up" ON "commontator_comments" ("cached_votes_up")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.6ms) CREATE INDEX "index_commontator_comments_on_c_id_and_c_type_and_t_id" ON "commontator_comments" ("creator_id", "creator_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.6ms) CREATE INDEX "index_commontator_comments_on_thread_id_and_created_at" ON "commontator_comments" ("thread_id", "created_at")  (0.6ms) CREATE TABLE "commontator_subscriptions" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "subscriber_type" varchar(255) NOT NULL, "subscriber_id" integer NOT NULL, "thread_id" integer NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.6ms) CREATE UNIQUE INDEX "index_commontator_subscriptions_on_s_id_and_s_type_and_t_id" ON "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index'   (0.6ms) CREATE INDEX "index_commontator_subscriptions_on_thread_id" ON "commontator_subscriptions" ("thread_id")  (0.5ms) CREATE TABLE "commontator_threads" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "commontable_type" varchar(255), "commontable_id" integer, "closed_at" datetime, "closer_type" varchar(255), "closer_id" integer, "created_at" datetime, "updated_at" datetime)   (0.5ms) CREATE UNIQUE INDEX "index_commontator_threads_on_c_id_and_c_type" ON "commontator_threads" ("commontable_id", "commontable_type")  (0.6ms) CREATE TABLE "dummy_models" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.5ms) CREATE TABLE "dummy_users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)  (0.5ms) CREATE TABLE "votes" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "votable_id" integer, "votable_type" varchar(255), "voter_id" integer, "voter_type" varchar(255), "vote_flag" boolean, "vote_scope" varchar(255), "vote_weight" integer, "created_at" datetime, "updated_at" datetime)   (0.5ms) CREATE INDEX "index_votes_on_votable_id_and_votable_type_and_vote_scope" ON "votes" ("votable_id", "votable_type", "vote_scope")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index'   (0.7ms) CREATE INDEX "index_votes_on_voter_id_and_voter_type_and_vote_scope" ON "votes" ("voter_id", "voter_type", "vote_scope")  (1.1ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)   (0.8ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.1ms) SELECT version FROM "schema_migrations"  (0.6ms) INSERT INTO "schema_migrations" (version) VALUES ('3')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('1')  (0.6ms) INSERT INTO "schema_migrations" (version) VALUES ('2')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.1ms) begin transaction ------------------------------------------------------------------------ Commontator::SubscriptionsMailer: test_0001_must create deliverable mail ------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (1.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.224499"], ["updated_at", "2014-10-20 16:59:39.224499"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.248940"], ["updated_at", "2014-10-20 16:59:39.248940"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.252039"], ["updated_at", "2014-10-20 16:59:39.252039"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.253130"], ["updated_at", "2014-10-20 16:59:39.253130"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 16:59:39.300007"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-10-20 16:59:39.300007"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 16:59:39.302550"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-10-20 16:59:39.302550"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:39.313182"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-10-20 16:59:39.313182"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/comments/_body.html.erb (3.5ms) Rendered /Users/dante/Desktop/commontator/app/views/commontator/subscriptions_mailer/comment_created.html.erb (32.9ms) Commontator::SubscriptionsMailer#comment_created: processed outbound mail in 55.9ms Sent mail to Undisclosed Recipients (7.6ms) Date: Mon, 20 Oct 2014 11:59:39 -0500 From: no-reply@dummy.com to: Undisclosed Recipients Message-ID: <54453f7b5c424_4dd3fe425833bd429961@Dantes-MacBook-Pro.local.mail> Subject: Dummy User #1 posted a comment on DummyModel #1 Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit

Dummy User #1 commented on DummyModel #1:

Something

Click here to view all comments on DummyModel #1.

 (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------- Commontator::Comment: test_0001_must be votable if acts_as_votable is installed -------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.386145"], ["updated_at", "2014-10-20 16:59:39.386145"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.387562"], ["updated_at", "2014-10-20 16:59:39.387562"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.388537"], ["updated_at", "2014-10-20 16:59:39.388537"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (2.8ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::Comment: test_0002_must know if it has been modified -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.395145"], ["updated_at", "2014-10-20 16:59:39.395145"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.396386"], ["updated_at", "2014-10-20 16:59:39.396386"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.397294"], ["updated_at", "2014-10-20 16:59:39.397294"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:39.399082"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-10-20 16:59:39.399082"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["body", "Something else"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-10-20 16:59:39.400966"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (2.0ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------- Commontator::Comment: test_0003_must know if it has been deleted ----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.404495"], ["updated_at", "2014-10-20 16:59:39.404495"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.405486"], ["updated_at", "2014-10-20 16:59:39.405486"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.406362"], ["updated_at", "2014-10-20 16:59:39.406362"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-10-20 16:59:39.407229') LIMIT 1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.408167"], ["updated_at", "2014-10-20 16:59:39.408167"]] SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "deleted_at", "editor_id", "editor_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:39.408644"], ["creator_id", 1], ["creator_type", "DummyUser"], ["deleted_at", "2014-10-20 16:59:39.407229"], ["editor_id", 2], ["editor_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-10-20 16:59:39.408644"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["updated_at", "2014-10-20 16:59:39.410162"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (2.0ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------- Commontator::Comment: test_0004_must make proper timestamps -----------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.413595"], ["updated_at", "2014-10-20 16:59:39.413595"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.415345"], ["updated_at", "2014-10-20 16:59:39.415345"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.416891"], ["updated_at", "2014-10-20 16:59:39.416891"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:39.419135"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-10-20 16:59:39.419135"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.421270"], ["updated_at", "2014-10-20 16:59:39.421270"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["body", "Something else"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-10-20 16:59:39.423027"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (2.3ms) rollback transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.429040"], ["updated_at", "2014-10-20 16:59:39.429040"]]  (0.9ms) commit transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.431843"], ["updated_at", "2014-10-20 16:59:39.431843"]]  (8.1ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.441323"], ["updated_at", "2014-10-20 16:59:39.441323"]]  (3.4ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:39.446545"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-10-20 16:59:39.446545"]]  (3.1ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 16:59:39.451188"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-10-20 16:59:39.451188"]]  (3.2ms) commit transaction Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY created_at ASC [["thread_id", 1]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.456970"], ["updated_at", "2014-10-20 16:59:39.456970"]]  (5.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.463661"], ["updated_at", "2014-10-20 16:59:39.463661"]]  (5.7ms) commit transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.470532"], ["updated_at", "2014-10-20 16:59:39.470532"]]  (0.5ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 16:59:39.473787"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-10-20 16:59:39.473787"]]  (3.3ms) commit transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.478196"], ["updated_at", "2014-10-20 16:59:39.478196"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 3], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 3) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 16:59:39.481553"], ["subscriber_id", 3], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-10-20 16:59:39.481553"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 3], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 3]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.486267"], ["updated_at", "2014-10-20 16:59:39.486267"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.487874"], ["updated_at", "2014-10-20 16:59:39.487874"]]  (5.8ms) commit transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 3], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.494726"], ["updated_at", "2014-10-20 16:59:39.494726"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 3 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 4], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 3 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 4) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 16:59:39.497962"], ["subscriber_id", 4], ["subscriber_type", "DummyUser"], ["thread_id", 3], ["updated_at", "2014-10-20 16:59:39.497962"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 3 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 4], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 3]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-10-20 16:59:39.497962') [["thread_id", 3]]  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 4 AND "commontator_comments"."thread_id" = 3 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:39.502999"], ["creator_id", 4], ["creator_type", "DummyUser"], ["thread_id", 3], ["updated_at", "2014-10-20 16:59:39.502999"]]  (3.3ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 3]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-10-20 16:59:39.497962') [["thread_id", 3]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 3 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 4], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction SQL (0.2ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-10-20 16:59:39.509861' WHERE "commontator_subscriptions"."id" = 3  (5.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 3]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-10-20 16:59:39.509861') [["thread_id", 3]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.518409"], ["updated_at", "2014-10-20 16:59:39.518409"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.520164"], ["updated_at", "2014-10-20 16:59:39.520164"]]  (6.1ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 4], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.528267"], ["updated_at", "2014-10-20 16:59:39.528267"]]  (3.2ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 5 AND "commontator_comments"."thread_id" = 4 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:39.533632"], ["creator_id", 5], ["creator_type", "DummyUser"], ["thread_id", 4], ["updated_at", "2014-10-20 16:59:39.533632"]]  (3.4ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 4 AND "commontator_threads"."id" != 4 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 4 [["closed_at", "2014-10-20 16:59:39.537694"], ["closer_id", 5], ["closer_type", "DummyUser"], ["updated_at", "2014-10-20 16:59:39.538960"]]  (1.5ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 4 LIMIT 1 [["thread_id", 4]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 4]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 4], ["commontable_type", "DummyModel"]]  (0.0ms) begin transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 4]] SQL (0.2ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "commontable_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 4 [["commontable_id", nil], ["commontable_type", nil], ["updated_at", "2014-10-20 16:59:39.545476"]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 4 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 4], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.546789"], ["updated_at", "2014-10-20 16:59:39.546789"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 4]]  (0.7ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 4 LIMIT 1 [["thread_id", 4]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 4]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 4], ["commontable_type", "DummyModel"]] Commontator::Comment Exists (0.0ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 4 LIMIT 1 [["thread_id", 5]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.550860"], ["updated_at", "2014-10-20 16:59:39.550860"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.552523"], ["updated_at", "2014-10-20 16:59:39.552523"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 5], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.554074"], ["updated_at", "2014-10-20 16:59:39.554074"]]  (0.7ms) commit transaction  (0.1ms) begin transaction DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", nil]] SQL (0.2ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 6 [["commontable_id", nil], ["updated_at", "2014-10-20 16:59:39.556304"]]  (0.7ms) commit transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 6]]  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.558313"], ["updated_at", "2014-10-20 16:59:39.558313"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.560076"], ["updated_at", "2014-10-20 16:59:39.560076"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 6], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.561731"], ["updated_at", "2014-10-20 16:59:39.561731"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 6 AND "commontator_threads"."id" != 7 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 7 [["closed_at", "2014-10-20 16:59:39.562976"], ["closer_id", 7], ["closer_type", "DummyUser"], ["updated_at", "2014-10-20 16:59:39.563785"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 6 AND "commontator_threads"."id" != 7 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 7 [["closed_at", nil], ["updated_at", "2014-10-20 16:59:39.565691"]]  (2.4ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.569017"], ["updated_at", "2014-10-20 16:59:39.569017"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.571114"], ["updated_at", "2014-10-20 16:59:39.571114"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 7], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.572908"], ["updated_at", "2014-10-20 16:59:39.572908"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.574666"], ["updated_at", "2014-10-20 16:59:39.574666"]]  (0.5ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.576403"], ["updated_at", "2014-10-20 16:59:39.576403"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 8], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.577956"], ["updated_at", "2014-10-20 16:59:39.577956"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 9 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 9], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 9 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 9) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 16:59:39.580994"], ["subscriber_id", 9], ["subscriber_type", "DummyUser"], ["thread_id", 9], ["updated_at", "2014-10-20 16:59:39.580994"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.582443"], ["updated_at", "2014-10-20 16:59:39.582443"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 9 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 10], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 9 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 10) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 16:59:39.584962"], ["subscriber_id", 10], ["subscriber_type", "DummyUser"], ["thread_id", 9], ["updated_at", "2014-10-20 16:59:39.584962"]]  (0.5ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 9]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 10]]  (0.1ms) begin transaction ----------------------------------------------------------------- Commontator::SharedHelper: test_0001_must show commontator thread -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.593320"], ["updated_at", "2014-10-20 16:59:39.593320"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.594490"], ["updated_at", "2014-10-20 16:59:39.594490"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Rendered /Users/dante/Desktop/commontator/app/views/commontator/shared/_thread.html.erb (0.7ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::ApplicationHelper: test_0001_must print javascript proc --------------------------------------------------------------------  (0.1ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0001_won't subscribe unless authorized ---------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.608384"], ["updated_at", "2014-10-20 16:59:39.608384"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.610073"], ["updated_at", "2014-10-20 16:59:39.610073"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.611299"], ["updated_at", "2014-10-20 16:59:39.611299"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 11) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 16:59:39.618992"], ["subscriber_id", 11], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.618992"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0002_must subscribe if authorized ----------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.624804"], ["updated_at", "2014-10-20 16:59:39.624804"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.627078"], ["updated_at", "2014-10-20 16:59:39.627078"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.628510"], ["updated_at", "2014-10-20 16:59:39.628510"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 11) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 16:59:39.634137"], ["subscriber_id", 11], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.634137"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 5ms (ActiveRecord: 0.4ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 6]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 11) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 16:59:39.657800"], ["subscriber_id", 11], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.657800"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 22ms (ActiveRecord: 0.4ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 7]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 11) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 16:59:39.664323"], ["subscriber_id", 11], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.664323"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.5ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0003_won't unsubscribe unless authorized -----------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.668667"], ["updated_at", "2014-10-20 16:59:39.668667"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.670784"], ["updated_at", "2014-10-20 16:59:39.670784"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.672228"], ["updated_at", "2014-10-20 16:59:39.672228"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 11) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 16:59:39.675783"], ["subscriber_id", 11], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.675783"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 6]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::SubscriptionsController: test_0004_must unsubscribe if authorized ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.686755"], ["updated_at", "2014-10-20 16:59:39.686755"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.687971"], ["updated_at", "2014-10-20 16:59:39.687971"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.688861"], ["updated_at", "2014-10-20 16:59:39.688861"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 11) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 16:59:39.691039"], ["subscriber_id", 11], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.691039"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 6]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 11) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 16:59:39.726135"], ["subscriber_id", 11], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.726135"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 7]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 11) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 16:59:39.730761"], ["subscriber_id", 11], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.730761"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 8]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------- Commontator::ThreadsController: test_0001_won't show unless authorized ----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.735971"], ["updated_at", "2014-10-20 16:59:39.735971"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.737167"], ["updated_at", "2014-10-20 16:59:39.737167"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.738063"], ["updated_at", "2014-10-20 16:59:39.738063"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.3ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::ThreadsController: test_0002_must show if authorized -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.743751"], ["updated_at", "2014-10-20 16:59:39.743751"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.744910"], ["updated_at", "2014-10-20 16:59:39.744910"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.745898"], ["updated_at", "2014-10-20 16:59:39.745898"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 9], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/9 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 9], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/9 Completed 302 Found in 2ms (ActiveRecord: 0.1ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 9], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/9 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.3ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------------------- Commontator::ThreadsController: test_0003_won't close unless authorized and open --------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.757182"], ["updated_at", "2014-10-20 16:59:39.757182"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.758405"], ["updated_at", "2014-10-20 16:59:39.758405"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.759309"], ["updated_at", "2014-10-20 16:59:39.759309"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-10-20 16:59:39.764460"], ["updated_at", "2014-10-20 16:59:39.765309"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------- Commontator::ThreadsController: test_0004_must close if authorized and open ---------------------------------------------------------------------------  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.769833"], ["updated_at", "2014-10-20 16:59:39.769833"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.771821"], ["updated_at", "2014-10-20 16:59:39.771821"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.773314"], ["updated_at", "2014-10-20 16:59:39.773314"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-10-20 16:59:39.776934"], ["closer_id", 11], ["closer_type", "DummyUser"], ["updated_at", "2014-10-20 16:59:39.778169"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", nil], ["updated_at", "2014-10-20 16:59:39.780981"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-10-20 16:59:39.782696"], ["updated_at", "2014-10-20 16:59:39.783380"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------- Commontator::ThreadsController: test_0005_won't reopen unless authorized and closed -----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.786061"], ["updated_at", "2014-10-20 16:59:39.786061"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.787310"], ["updated_at", "2014-10-20 16:59:39.787310"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.788208"], ["updated_at", "2014-10-20 16:59:39.788208"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-10-20 16:59:39.788778"], ["updated_at", "2014-10-20 16:59:39.789497"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", nil], ["updated_at", "2014-10-20 16:59:39.795981"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.6ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::ThreadsController: test_0006_must reopen if authorized and closed ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.800123"], ["updated_at", "2014-10-20 16:59:39.800123"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.801364"], ["updated_at", "2014-10-20 16:59:39.801364"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.802263"], ["updated_at", "2014-10-20 16:59:39.802263"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-10-20 16:59:39.802833"], ["updated_at", "2014-10-20 16:59:39.803656"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", nil], ["updated_at", "2014-10-20 16:59:39.807002"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-10-20 16:59:39.808462"], ["updated_at", "2014-10-20 16:59:39.809185"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", nil], ["updated_at", "2014-10-20 16:59:39.811587"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.816080"], ["updated_at", "2014-10-20 16:59:39.816080"]]  (0.7ms) commit transaction  (0.1ms) begin transaction --------------------------------------------------------------- Commontator::Subscription: test_0001_must count unread comments ---------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.819119"], ["updated_at", "2014-10-20 16:59:39.819119"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.820660"], ["updated_at", "2014-10-20 16:59:39.820660"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.821923"], ["updated_at", "2014-10-20 16:59:39.821923"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 16:59:39.823965"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.823965"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-10-20 16:59:39.823965') [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:39.826742"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.826742"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-10-20 16:59:39.823965') [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 16:59:39.830140"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.830140"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-10-20 16:59:39.823965') [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-10-20 16:59:39.832445' WHERE "commontator_subscriptions"."id" = 6  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-10-20 16:59:39.832445') [["thread_id", 10]]  (0.5ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------------- Commontator::CommentsController: test_0001_won't get new unless authorized --------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.837919"], ["updated_at", "2014-10-20 16:59:39.837919"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.839925"], ["updated_at", "2014-10-20 16:59:39.839925"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.841374"], ["updated_at", "2014-10-20 16:59:39.841374"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:39.843870"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.843870"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------- Commontator::CommentsController: test_0002_must get new if authorized ---------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.850142"], ["updated_at", "2014-10-20 16:59:39.850142"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.851369"], ["updated_at", "2014-10-20 16:59:39.851369"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.852316"], ["updated_at", "2014-10-20 16:59:39.852316"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:39.854018"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.854018"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 1ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0003_won't create unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.863151"], ["updated_at", "2014-10-20 16:59:39.863151"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.864349"], ["updated_at", "2014-10-20 16:59:39.864349"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.865254"], ["updated_at", "2014-10-20 16:59:39.865254"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:39.866946"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.866946"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-10-20 16:59:39.870219"], ["updated_at", "2014-10-20 16:59:39.871063"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0004_must create if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.874650"], ["updated_at", "2014-10-20 16:59:39.874650"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.875853"], ["updated_at", "2014-10-20 16:59:39.875853"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.876827"], ["updated_at", "2014-10-20 16:59:39.876827"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:39.878529"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.878529"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 16:59:39.882183"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.882183"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Another thing"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Another thing' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Another thing"], ["created_at", "2014-10-20 16:59:39.886515"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.886515"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"And this too"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'And this too' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "And this too"], ["created_at", "2014-10-20 16:59:39.891112"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.891112"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 24ms (ActiveRecord: 0.3ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0005_won't create if double posting -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.915814"], ["updated_at", "2014-10-20 16:59:39.915814"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.917474"], ["updated_at", "2014-10-20 16:59:39.917474"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.918605"], ["updated_at", "2014-10-20 16:59:39.918605"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:39.920612"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.920612"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 16:59:39.929298"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.929298"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------------- Commontator::CommentsController: test_0006_won't edit unless authorized -----------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.937865"], ["updated_at", "2014-10-20 16:59:39.937865"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.940076"], ["updated_at", "2014-10-20 16:59:39.940076"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.941589"], ["updated_at", "2014-10-20 16:59:39.941589"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:39.944139"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.944139"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 4ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.951613"], ["updated_at", "2014-10-20 16:59:39.951613"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 16:59:39.956604"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.956604"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------ Commontator::CommentsController: test_0007_must edit if authorized ------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.961632"], ["updated_at", "2014-10-20 16:59:39.961632"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.963009"], ["updated_at", "2014-10-20 16:59:39.963009"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.964131"], ["updated_at", "2014-10-20 16:59:39.964131"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:39.966151"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.966151"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0008_won't update unless authorized -------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.980641"], ["updated_at", "2014-10-20 16:59:39.980641"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.981924"], ["updated_at", "2014-10-20 16:59:39.981924"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:39.982870"], ["updated_at", "2014-10-20 16:59:39.982870"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:39.984714"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.984714"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:39.991239"], ["updated_at", "2014-10-20 16:59:39.991239"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 16:59:39.996441"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:39.996441"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0009_must update if authorized --------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.002452"], ["updated_at", "2014-10-20 16:59:40.002452"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.003769"], ["updated_at", "2014-10-20 16:59:40.003769"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:40.005164"], ["updated_at", "2014-10-20 16:59:40.005164"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:40.007218"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:40.007218"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["body", "Something else"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-10-20 16:59:40.013285"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.5ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------------- Commontator::CommentsController: test_0010_won't delete unless authorized and not deleted -----------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.026236"], ["updated_at", "2014-10-20 16:59:40.026236"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.027637"], ["updated_at", "2014-10-20 16:59:40.027637"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:40.028762"], ["updated_at", "2014-10-20 16:59:40.028762"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:40.030622"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:40.030622"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 16:59:40.036930') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 16:59:40.036930"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-10-20 16:59:40.038780"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.2ms)  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 16:59:40.045908"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:40.045908"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-10-20 16:59:40.047609"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------------ Commontator::CommentsController: test_0011_must delete if authorized and not deleted ------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.053307"], ["updated_at", "2014-10-20 16:59:40.053307"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.054705"], ["updated_at", "2014-10-20 16:59:40.054705"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:40.055910"], ["updated_at", "2014-10-20 16:59:40.055910"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:40.057943"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:40.057943"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.2ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 16:59:40.093377') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 16:59:40.093377"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-10-20 16:59:40.095039"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.6ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.097100"], ["updated_at", "2014-10-20 16:59:40.097100"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 16:59:40.098616"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:40.098616"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-10-20 16:59:40.100246"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 16:59:40.102668') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 16:59:40.102668"], ["editor_id", 13], ["updated_at", "2014-10-20 16:59:40.103687"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 12], ["updated_at", "2014-10-20 16:59:40.105978"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 16:59:40.108080') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 16:59:40.108080"], ["editor_id", 13], ["updated_at", "2014-10-20 16:59:40.109059"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (2.1ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------------------- Commontator::CommentsController: test_0012_won't undelete unless authorized and deleted ---------------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.114184"], ["updated_at", "2014-10-20 16:59:40.114184"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.115859"], ["updated_at", "2014-10-20 16:59:40.115859"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:40.116855"], ["updated_at", "2014-10-20 16:59:40.116855"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:40.118655"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:40.118655"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 16:59:40.119305') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 16:59:40.119305"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-10-20 16:59:40.120142"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-10-20 16:59:40.127856"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.132054"], ["updated_at", "2014-10-20 16:59:40.132054"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 16:59:40.132598') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 16:59:40.132598"], ["editor_id", 13], ["updated_at", "2014-10-20 16:59:40.133496"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 13]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 16:59:40.137407"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:40.137407"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 12], ["updated_at", "2014-10-20 16:59:40.139247"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 16:59:40.139727') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 16:59:40.139727"], ["updated_at", "2014-10-20 16:59:40.140452"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------------------- Commontator::CommentsController: test_0013_must undelete if authorized and deleted ----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.145760"], ["updated_at", "2014-10-20 16:59:40.145760"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.147001"], ["updated_at", "2014-10-20 16:59:40.147001"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:40.148045"], ["updated_at", "2014-10-20 16:59:40.148045"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:40.149732"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:40.149732"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 16:59:40.150375') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 16:59:40.150375"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-10-20 16:59:40.151184"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-10-20 16:59:40.156950"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.158777"], ["updated_at", "2014-10-20 16:59:40.158777"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 16:59:40.160251"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:40.160251"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 16:59:40.160888') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 16:59:40.160888"], ["updated_at", "2014-10-20 16:59:40.161700"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 13], ["updated_at", "2014-10-20 16:59:40.164587"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 16:59:40.165774') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 16:59:40.165774"], ["editor_id", 12], ["updated_at", "2014-10-20 16:59:40.166634"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 13], ["updated_at", "2014-10-20 16:59:40.169675"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0014_won't upvote unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.172362"], ["updated_at", "2014-10-20 16:59:40.172362"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.173619"], ["updated_at", "2014-10-20 16:59:40.173619"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:40.174532"], ["updated_at", "2014-10-20 16:59:40.174532"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:40.176198"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:40.176198"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.2ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.186634"], ["updated_at", "2014-10-20 16:59:40.186634"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0015_must upvote if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.193216"], ["updated_at", "2014-10-20 16:59:40.193216"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.194395"], ["updated_at", "2014-10-20 16:59:40.194395"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:40.195318"], ["updated_at", "2014-10-20 16:59:40.195318"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:40.196967"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:40.196967"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.197840"], ["updated_at", "2014-10-20 16:59:40.197840"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-10-20 16:59:40.207696"], ["updated_at", "2014-10-20 16:59:40.207696"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 13ms (ActiveRecord: 0.8ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 7ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-10-20 16:59:40.224676"], ["vote_flag", "f"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-10-20 16:59:40.231199"], ["vote_flag", "t"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------- Commontator::CommentsController: test_0016_won't downvote unless authorized ---------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.237503"], ["updated_at", "2014-10-20 16:59:40.237503"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.238779"], ["updated_at", "2014-10-20 16:59:40.238779"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:40.239729"], ["updated_at", "2014-10-20 16:59:40.239729"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:40.241380"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:40.241380"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.249866"], ["updated_at", "2014-10-20 16:59:40.249866"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.3ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------------- Commontator::CommentsController: test_0017_must downvote if authorized ----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.278787"], ["updated_at", "2014-10-20 16:59:40.278787"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.280227"], ["updated_at", "2014-10-20 16:59:40.280227"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:40.281302"], ["updated_at", "2014-10-20 16:59:40.281302"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:40.283128"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:40.283128"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.284291"], ["updated_at", "2014-10-20 16:59:40.284291"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-10-20 16:59:40.289587"], ["updated_at", "2014-10-20 16:59:40.289587"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "f"], ["vote_weight", 1], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 7ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 7ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-10-20 16:59:40.305485"], ["vote_flag", "t"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-10-20 16:59:40.313012"], ["vote_flag", "f"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 7ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.7ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0018_won't unvote unless authorized -------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.320323"], ["updated_at", "2014-10-20 16:59:40.320323"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.321903"], ["updated_at", "2014-10-20 16:59:40.321903"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:40.323136"], ["updated_at", "2014-10-20 16:59:40.323136"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:40.325343"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:40.325343"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-10-20 16:59:40.327954"], ["updated_at", "2014-10-20 16:59:40.327954"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 12], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.339099"], ["updated_at", "2014-10-20 16:59:40.339099"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0019_must unvote if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.346767"], ["updated_at", "2014-10-20 16:59:40.346767"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.348477"], ["updated_at", "2014-10-20 16:59:40.348477"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:40.350404"], ["updated_at", "2014-10-20 16:59:40.350404"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:40.353507"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:40.353507"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.354900"], ["updated_at", "2014-10-20 16:59:40.354900"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-10-20 16:59:40.357742"], ["updated_at", "2014-10-20 16:59:40.357742"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.2ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 8ms (ActiveRecord: 0.8ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.2ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-10-20 16:59:40.379604"], ["updated_at", "2014-10-20 16:59:40.379604"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "f"], ["vote_weight", 1], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 8ms (ActiveRecord: 0.7ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::CommentsController: test_0020_won't send mail if recipients empty ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.394706"], ["updated_at", "2014-10-20 16:59:40.394706"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.396094"], ["updated_at", "2014-10-20 16:59:40.396094"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:40.397152"], ["updated_at", "2014-10-20 16:59:40.397152"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:40.398850"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:40.398850"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.399868"], ["updated_at", "2014-10-20 16:59:40.399868"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 16:59:40.404026"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:40.404026"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.4ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------- Commontator::CommentsController: test_0021_must send mail if recipients not empty ---------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.407873"], ["updated_at", "2014-10-20 16:59:40.407873"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.409063"], ["updated_at", "2014-10-20 16:59:40.409063"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 16:59:40.410032"], ["updated_at", "2014-10-20 16:59:40.410032"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 16:59:40.411710"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:40.411710"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.412658"], ["updated_at", "2014-10-20 16:59:40.412658"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 13], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 13) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 16:59:40.414763"], ["subscriber_id", 13], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:40.414763"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 16:59:40.418743"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 16:59:40.418743"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 13]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 5ms (ActiveRecord: 0.4ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 16:59:40.454848"], ["updated_at", "2014-10-20 16:59:40.454848"]]  (0.6ms) commit transaction  (1.4ms) CREATE TABLE "commontator_comments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "creator_type" varchar(255), "creator_id" integer, "editor_type" varchar(255), "editor_id" integer, "thread_id" integer NOT NULL, "body" text NOT NULL, "deleted_at" datetime, "cached_votes_up" integer DEFAULT 0, "cached_votes_down" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime)   (0.1ms) select sqlite_version(*)  (0.9ms) CREATE INDEX "index_commontator_comments_on_cached_votes_down" ON "commontator_comments" ("cached_votes_down")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'  (0.9ms) CREATE INDEX "index_commontator_comments_on_cached_votes_up" ON "commontator_comments" ("cached_votes_up")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.9ms) CREATE INDEX "index_commontator_comments_on_c_id_and_c_type_and_t_id" ON "commontator_comments" ("creator_id", "creator_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_comments_on_thread_id_and_created_at" ON "commontator_comments" ("thread_id", "created_at")  (0.8ms) CREATE TABLE "commontator_subscriptions" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "subscriber_type" varchar(255) NOT NULL, "subscriber_id" integer NOT NULL, "thread_id" integer NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE UNIQUE INDEX "index_commontator_subscriptions_on_s_id_and_s_type_and_t_id" ON "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_subscriptions_on_thread_id" ON "commontator_subscriptions" ("thread_id")  (0.8ms) CREATE TABLE "commontator_threads" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "commontable_type" varchar(255), "commontable_id" integer, "closed_at" datetime, "closer_type" varchar(255), "closer_id" integer, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE UNIQUE INDEX "index_commontator_threads_on_c_id_and_c_type" ON "commontator_threads" ("commontable_id", "commontable_type")  (0.8ms) CREATE TABLE "dummy_models" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.7ms) CREATE TABLE "dummy_users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)  (0.8ms) CREATE TABLE "votes" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "votable_id" integer, "votable_type" varchar(255), "voter_id" integer, "voter_type" varchar(255), "vote_flag" boolean, "vote_scope" varchar(255), "vote_weight" integer, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE INDEX "index_votes_on_votable_id_and_votable_type_and_vote_scope" ON "votes" ("votable_id", "votable_type", "vote_scope")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index'   (0.8ms) CREATE INDEX "index_votes_on_voter_id_and_voter_type_and_vote_scope" ON "votes" ("voter_id", "voter_type", "vote_scope")  (0.9ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)   (0.7ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.1ms) SELECT version FROM "schema_migrations"  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('3')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('1')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('2')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.1ms) begin transaction SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.651001"], ["updated_at", "2014-10-20 21:51:38.651001"]]  (0.5ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.657036"], ["updated_at", "2014-10-20 21:51:38.657036"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.673372"], ["updated_at", "2014-10-20 21:51:38.673372"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:38.676558"], ["updated_at", "2014-10-20 21:51:38.676558"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.2ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-10-20 21:51:38.678276"], ["closer_id", 2], ["closer_type", "DummyUser"], ["updated_at", "2014-10-20 21:51:38.686223"]]  (0.6ms) commit transaction  (0.1ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.2ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-10-20 21:51:38.689707"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.691606"], ["updated_at", "2014-10-20 21:51:38.691606"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.693358"], ["updated_at", "2014-10-20 21:51:38.693358"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:38.694907"], ["updated_at", "2014-10-20 21:51:38.694907"]]  (0.6ms) commit transaction  (0.1ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.696519"], ["updated_at", "2014-10-20 21:51:38.696519"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.698035"], ["updated_at", "2014-10-20 21:51:38.698035"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 3], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:38.699478"], ["updated_at", "2014-10-20 21:51:38.699478"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 3 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 4], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 3 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 4) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 21:51:38.716291"], ["subscriber_id", 4], ["subscriber_type", "DummyUser"], ["thread_id", 3], ["updated_at", "2014-10-20 21:51:38.716291"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 3 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 4], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 3]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-10-20 21:51:38.716291') [["thread_id", 3]]  (0.0ms) begin transaction Commontator::Comment Exists (0.2ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 4 AND "commontator_comments"."thread_id" = 3 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:38.728432"], ["creator_id", 4], ["creator_type", "DummyUser"], ["thread_id", 3], ["updated_at", "2014-10-20 21:51:38.728432"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.2ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 3]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-10-20 21:51:38.716291') [["thread_id", 3]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 3 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 4], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction SQL (0.2ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-10-20 21:51:38.734338' WHERE "commontator_subscriptions"."id" = 1  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 3]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-10-20 21:51:38.734338') [["thread_id", 3]]  (0.1ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.737839"], ["updated_at", "2014-10-20 21:51:38.737839"]]  (0.5ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.739460"], ["updated_at", "2014-10-20 21:51:38.739460"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 4], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:38.740939"], ["updated_at", "2014-10-20 21:51:38.740939"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 4 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 5], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 4 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 5) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 21:51:38.743829"], ["subscriber_id", 5], ["subscriber_type", "DummyUser"], ["thread_id", 4], ["updated_at", "2014-10-20 21:51:38.743829"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.745348"], ["updated_at", "2014-10-20 21:51:38.745348"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 4 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 6], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 4 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 6) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 21:51:38.747874"], ["subscriber_id", 6], ["subscriber_type", "DummyUser"], ["thread_id", 4], ["updated_at", "2014-10-20 21:51:38.747874"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 4 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 5], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 4]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 5]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 4 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 6], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 4]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 6]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.752157"], ["updated_at", "2014-10-20 21:51:38.752157"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.753781"], ["updated_at", "2014-10-20 21:51:38.753781"]]  (0.6ms) commit transaction  (0.1ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 5], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:38.755259"], ["updated_at", "2014-10-20 21:51:38.755259"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 5 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 7], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 5 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 7) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 21:51:38.757999"], ["subscriber_id", 7], ["subscriber_type", "DummyUser"], ["thread_id", 5], ["updated_at", "2014-10-20 21:51:38.757999"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.759506"], ["updated_at", "2014-10-20 21:51:38.759506"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 5 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 8], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 5 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 8) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 21:51:38.762110"], ["subscriber_id", 8], ["subscriber_type", "DummyUser"], ["thread_id", 5], ["updated_at", "2014-10-20 21:51:38.762110"]]  (0.4ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 5]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 7]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 8]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.765282"], ["updated_at", "2014-10-20 21:51:38.765282"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.766862"], ["updated_at", "2014-10-20 21:51:38.766862"]]  (0.6ms) commit transaction  (0.1ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 6], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:38.768376"], ["updated_at", "2014-10-20 21:51:38.768376"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 9 AND "commontator_comments"."thread_id" = 6 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:38.770660"], ["creator_id", 9], ["creator_type", "DummyUser"], ["thread_id", 6], ["updated_at", "2014-10-20 21:51:38.770660"]]  (0.5ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 6 AND "commontator_threads"."id" != 6 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.2ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 6 [["closed_at", "2014-10-20 21:51:38.771891"], ["closer_id", 9], ["closer_type", "DummyUser"], ["updated_at", "2014-10-20 21:51:38.772738"]]  (0.6ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 2 LIMIT 1 [["thread_id", 6]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 6], ["commontable_type", "DummyModel"]]  (0.0ms) begin transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 6]] SQL (0.3ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "commontable_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 6 [["commontable_id", nil], ["commontable_type", nil], ["updated_at", "2014-10-20 21:51:38.777291"]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 6 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 6], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:38.779089"], ["updated_at", "2014-10-20 21:51:38.779089"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 6]]  (0.7ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 2 LIMIT 1 [["thread_id", 6]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 6], ["commontable_type", "DummyModel"]] Commontator::Comment Exists (0.0ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 2 LIMIT 1 [["thread_id", 7]]  (0.1ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.783372"], ["updated_at", "2014-10-20 21:51:38.783372"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.785002"], ["updated_at", "2014-10-20 21:51:38.785002"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 7], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:38.786623"], ["updated_at", "2014-10-20 21:51:38.786623"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 10 AND "commontator_comments"."thread_id" = 8 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:38.789140"], ["creator_id", 10], ["creator_type", "DummyUser"], ["thread_id", 8], ["updated_at", "2014-10-20 21:51:38.789140"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 10 AND "commontator_comments"."thread_id" = 8 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 21:51:38.791373"], ["creator_id", 10], ["creator_type", "DummyUser"], ["thread_id", 8], ["updated_at", "2014-10-20 21:51:38.791373"]]  (0.6ms) commit transaction Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 8]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY created_at ASC [["thread_id", 8]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.794075"], ["updated_at", "2014-10-20 21:51:38.794075"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.795756"], ["updated_at", "2014-10-20 21:51:38.795756"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 8], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:38.797206"], ["updated_at", "2014-10-20 21:51:38.797206"]]  (0.6ms) commit transaction  (0.0ms) begin transaction DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", nil]] SQL (0.2ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 9 [["commontable_id", nil], ["updated_at", "2014-10-20 21:51:38.799098"]]  (0.5ms) commit transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) begin transaction ------------------------------------------------------------------------ Commontator::SubscriptionsMailer: test_0001_must create deliverable mail ------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.811827"], ["updated_at", "2014-10-20 21:51:38.811827"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.813232"], ["updated_at", "2014-10-20 21:51:38.813232"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:38.814223"], ["updated_at", "2014-10-20 21:51:38.814223"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.815051"], ["updated_at", "2014-10-20 21:51:38.815051"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 21:51:38.817352"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:38.817352"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 13], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 13) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 21:51:38.819374"], ["subscriber_id", 13], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:38.819374"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:38.820963"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:38.820963"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 13]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/comments/_body.html.erb (2.5ms) Rendered /Users/dante/Desktop/commontator/app/views/commontator/subscriptions_mailer/comment_created.html.erb (6.5ms) Commontator::SubscriptionsMailer#comment_created: processed outbound mail in 22.6ms Sent mail to Undisclosed Recipients (6.4ms) Date: Mon, 20 Oct 2014 16:51:38 -0500 From: no-reply@dummy.com to: Undisclosed Recipients Message-ID: <544583eacf9fd_a103fe06482dbe089824@Dantes-MacBook-Pro.local.mail> Subject: Dummy User #12 posted a comment on DummyModel #9 Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit

Dummy User #12 commented on DummyModel #9:

Something

Click here to view all comments on DummyModel #9.

 (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::SharedHelper: test_0001_must show commontator thread -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.861792"], ["updated_at", "2014-10-20 21:51:38.861792"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:38.863000"], ["updated_at", "2014-10-20 21:51:38.863000"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Rendered /Users/dante/Desktop/commontator/app/views/commontator/shared/_thread.html.erb (0.7ms)  (0.3ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::ApplicationHelper: test_0001_must print javascript proc --------------------------------------------------------------------  (0.0ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------- Commontator::Comment: test_0001_must be votable if acts_as_votable is installed -------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.872160"], ["updated_at", "2014-10-20 21:51:38.872160"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.873250"], ["updated_at", "2014-10-20 21:51:38.873250"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:38.874175"], ["updated_at", "2014-10-20 21:51:38.874175"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::Comment: test_0002_must know if it has been modified -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.879434"], ["updated_at", "2014-10-20 21:51:38.879434"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.880635"], ["updated_at", "2014-10-20 21:51:38.880635"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:38.881566"], ["updated_at", "2014-10-20 21:51:38.881566"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:38.883337"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:38.883337"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["body", "Something else"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-10-20 21:51:38.884756"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.3ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------- Commontator::Comment: test_0003_must know if it has been deleted ----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.886301"], ["updated_at", "2014-10-20 21:51:38.886301"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.887278"], ["updated_at", "2014-10-20 21:51:38.887278"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:38.888166"], ["updated_at", "2014-10-20 21:51:38.888166"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 21:51:38.889052') LIMIT 1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.890061"], ["updated_at", "2014-10-20 21:51:38.890061"]] SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "deleted_at", "editor_id", "editor_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:38.890554"], ["creator_id", 12], ["creator_type", "DummyUser"], ["deleted_at", "2014-10-20 21:51:38.889052"], ["editor_id", 13], ["editor_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:38.890554"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-10-20 21:51:38.892284"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------- Commontator::Comment: test_0004_must make proper timestamps -----------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.893820"], ["updated_at", "2014-10-20 21:51:38.893820"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.895552"], ["updated_at", "2014-10-20 21:51:38.895552"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:38.896616"], ["updated_at", "2014-10-20 21:51:38.896616"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:38.898345"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:38.898345"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.899928"], ["updated_at", "2014-10-20 21:51:38.899928"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["body", "Something else"], ["editor_id", 13], ["editor_type", "DummyUser"], ["updated_at", "2014-10-20 21:51:38.901258"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0001_won't subscribe unless authorized ---------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.904303"], ["updated_at", "2014-10-20 21:51:38.904303"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.905347"], ["updated_at", "2014-10-20 21:51:38.905347"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:38.906287"], ["updated_at", "2014-10-20 21:51:38.906287"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 21:51:38.913600"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:38.913600"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0002_must subscribe if authorized ----------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.918620"], ["updated_at", "2014-10-20 21:51:38.918620"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.919686"], ["updated_at", "2014-10-20 21:51:38.919686"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:38.920581"], ["updated_at", "2014-10-20 21:51:38.920581"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 21:51:38.923993"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:38.923993"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 6]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 21:51:38.929118"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:38.929118"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.4ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 7]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 21:51:38.935053"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:38.935053"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.4ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0003_won't unsubscribe unless authorized -----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.938062"], ["updated_at", "2014-10-20 21:51:38.938062"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.939108"], ["updated_at", "2014-10-20 21:51:38.939108"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:38.940052"], ["updated_at", "2014-10-20 21:51:38.940052"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 21:51:38.942036"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:38.942036"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 6]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::SubscriptionsController: test_0004_must unsubscribe if authorized ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.949831"], ["updated_at", "2014-10-20 21:51:38.949831"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.950915"], ["updated_at", "2014-10-20 21:51:38.950915"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:38.951840"], ["updated_at", "2014-10-20 21:51:38.951840"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 21:51:38.953907"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:38.953907"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 6]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 21:51:38.959262"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:38.959262"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 7]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 21:51:38.963941"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:38.963941"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 8]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.968893"], ["updated_at", "2014-10-20 21:51:38.968893"]]  (0.6ms) commit transaction  (0.0ms) begin transaction --------------------------------------------------------------- Commontator::Subscription: test_0001_must count unread comments ---------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.971526"], ["updated_at", "2014-10-20 21:51:38.971526"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.972666"], ["updated_at", "2014-10-20 21:51:38.972666"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:38.973630"], ["updated_at", "2014-10-20 21:51:38.973630"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 21:51:38.975131"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:38.975131"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-10-20 21:51:38.975131') [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:38.977574"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:38.977574"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-10-20 21:51:38.975131') [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 21:51:38.982157"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:38.982157"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-10-20 21:51:38.975131') [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-10-20 21:51:38.984710' WHERE "commontator_subscriptions"."id" = 6  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-10-20 21:51:38.984710') [["thread_id", 10]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------- Commontator::ThreadsController: test_0001_won't show unless authorized ----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.989419"], ["updated_at", "2014-10-20 21:51:38.989419"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:38.990652"], ["updated_at", "2014-10-20 21:51:38.990652"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:38.991596"], ["updated_at", "2014-10-20 21:51:38.991596"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::ThreadsController: test_0002_must show if authorized -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.003396"], ["updated_at", "2014-10-20 21:51:39.003396"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.004545"], ["updated_at", "2014-10-20 21:51:39.004545"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.005475"], ["updated_at", "2014-10-20 21:51:39.005475"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 10], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 10], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/10 Completed 302 Found in 2ms (ActiveRecord: 0.1ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 10], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------------------- Commontator::ThreadsController: test_0003_won't close unless authorized and open --------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.016028"], ["updated_at", "2014-10-20 21:51:39.016028"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.017139"], ["updated_at", "2014-10-20 21:51:39.017139"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.018088"], ["updated_at", "2014-10-20 21:51:39.018088"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-10-20 21:51:39.022867"], ["updated_at", "2014-10-20 21:51:39.023663"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------- Commontator::ThreadsController: test_0004_must close if authorized and open ---------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.027926"], ["updated_at", "2014-10-20 21:51:39.027926"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.029870"], ["updated_at", "2014-10-20 21:51:39.029870"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.031041"], ["updated_at", "2014-10-20 21:51:39.031041"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-10-20 21:51:39.033674"], ["closer_id", 12], ["closer_type", "DummyUser"], ["updated_at", "2014-10-20 21:51:39.034583"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", nil], ["updated_at", "2014-10-20 21:51:39.036950"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-10-20 21:51:39.038688"], ["updated_at", "2014-10-20 21:51:39.039472"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------- Commontator::ThreadsController: test_0005_won't reopen unless authorized and closed -----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.042355"], ["updated_at", "2014-10-20 21:51:39.042355"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.043420"], ["updated_at", "2014-10-20 21:51:39.043420"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.044307"], ["updated_at", "2014-10-20 21:51:39.044307"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-10-20 21:51:39.044891"], ["updated_at", "2014-10-20 21:51:39.045798"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", nil], ["updated_at", "2014-10-20 21:51:39.053665"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::ThreadsController: test_0006_must reopen if authorized and closed ------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.057819"], ["updated_at", "2014-10-20 21:51:39.057819"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.059607"], ["updated_at", "2014-10-20 21:51:39.059607"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.061084"], ["updated_at", "2014-10-20 21:51:39.061084"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-10-20 21:51:39.061953"], ["updated_at", "2014-10-20 21:51:39.063006"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", nil], ["updated_at", "2014-10-20 21:51:39.067803"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-10-20 21:51:39.069698"], ["updated_at", "2014-10-20 21:51:39.070537"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", nil], ["updated_at", "2014-10-20 21:51:39.073334"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------------- Commontator::CommentsController: test_0001_won't get new unless authorized --------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.077708"], ["updated_at", "2014-10-20 21:51:39.077708"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.079643"], ["updated_at", "2014-10-20 21:51:39.079643"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.081145"], ["updated_at", "2014-10-20 21:51:39.081145"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:39.083644"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.083644"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------- Commontator::CommentsController: test_0002_must get new if authorized ---------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.090547"], ["updated_at", "2014-10-20 21:51:39.090547"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.092522"], ["updated_at", "2014-10-20 21:51:39.092522"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.094079"], ["updated_at", "2014-10-20 21:51:39.094079"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:39.096596"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.096596"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0003_won't create unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.106343"], ["updated_at", "2014-10-20 21:51:39.106343"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.107501"], ["updated_at", "2014-10-20 21:51:39.107501"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.108477"], ["updated_at", "2014-10-20 21:51:39.108477"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.3ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:39.110355"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.110355"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-10-20 21:51:39.114692"], ["updated_at", "2014-10-20 21:51:39.115638"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0004_must create if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.119440"], ["updated_at", "2014-10-20 21:51:39.119440"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.120678"], ["updated_at", "2014-10-20 21:51:39.120678"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.121695"], ["updated_at", "2014-10-20 21:51:39.121695"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:39.123361"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.123361"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 21:51:39.126862"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.126862"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Another thing"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Another thing' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Another thing"], ["created_at", "2014-10-20 21:51:39.131237"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.131237"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"And this too"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'And this too' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "And this too"], ["created_at", "2014-10-20 21:51:39.135279"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.135279"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0005_won't create if double posting -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.138418"], ["updated_at", "2014-10-20 21:51:39.138418"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.139516"], ["updated_at", "2014-10-20 21:51:39.139516"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.140448"], ["updated_at", "2014-10-20 21:51:39.140448"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:39.142105"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.142105"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 21:51:39.149213"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.149213"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------- Commontator::CommentsController: test_0006_won't edit unless authorized -----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.155822"], ["updated_at", "2014-10-20 21:51:39.155822"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.156957"], ["updated_at", "2014-10-20 21:51:39.156957"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.157945"], ["updated_at", "2014-10-20 21:51:39.157945"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:39.159612"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.159612"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.2ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 4ms (ActiveRecord: 0.4ms)  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.165835"], ["updated_at", "2014-10-20 21:51:39.165835"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 21:51:39.169995"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.169995"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------ Commontator::CommentsController: test_0007_must edit if authorized ------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.174777"], ["updated_at", "2014-10-20 21:51:39.174777"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.175974"], ["updated_at", "2014-10-20 21:51:39.175974"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.176943"], ["updated_at", "2014-10-20 21:51:39.176943"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:39.178546"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.178546"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0008_won't update unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.190755"], ["updated_at", "2014-10-20 21:51:39.190755"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.191993"], ["updated_at", "2014-10-20 21:51:39.191993"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.192976"], ["updated_at", "2014-10-20 21:51:39.192976"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.2ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:39.195130"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.195130"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.207487"], ["updated_at", "2014-10-20 21:51:39.207487"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 21:51:39.211936"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.211936"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0009_must update if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.217037"], ["updated_at", "2014-10-20 21:51:39.217037"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.218194"], ["updated_at", "2014-10-20 21:51:39.218194"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.219182"], ["updated_at", "2014-10-20 21:51:39.219182"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:39.220780"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.220780"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["body", "Something else"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-10-20 21:51:39.225644"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.2ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 5ms (ActiveRecord: 0.5ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------------- Commontator::CommentsController: test_0010_won't delete unless authorized and not deleted -----------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.239094"], ["updated_at", "2014-10-20 21:51:39.239094"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.240293"], ["updated_at", "2014-10-20 21:51:39.240293"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.241294"], ["updated_at", "2014-10-20 21:51:39.241294"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:39.242956"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.242956"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 21:51:39.247961') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 21:51:39.247961"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-10-20 21:51:39.249329"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 21:51:39.254538"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.254538"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-10-20 21:51:39.255963"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------------ Commontator::CommentsController: test_0011_must delete if authorized and not deleted ------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.260776"], ["updated_at", "2014-10-20 21:51:39.260776"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.261873"], ["updated_at", "2014-10-20 21:51:39.261873"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.262809"], ["updated_at", "2014-10-20 21:51:39.262809"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:39.264354"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.264354"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 21:51:39.267776') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 21:51:39.267776"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-10-20 21:51:39.268739"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.270507"], ["updated_at", "2014-10-20 21:51:39.270507"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 21:51:39.271964"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.271964"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-10-20 21:51:39.273584"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 21:51:39.275701') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 21:51:39.275701"], ["editor_id", 13], ["updated_at", "2014-10-20 21:51:39.276646"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 12], ["updated_at", "2014-10-20 21:51:39.279933"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 21:51:39.282649') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 21:51:39.282649"], ["editor_id", 13], ["updated_at", "2014-10-20 21:51:39.283723"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------------- Commontator::CommentsController: test_0012_won't undelete unless authorized and deleted ---------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.286606"], ["updated_at", "2014-10-20 21:51:39.286606"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.287705"], ["updated_at", "2014-10-20 21:51:39.287705"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.288648"], ["updated_at", "2014-10-20 21:51:39.288648"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:39.290245"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.290245"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 21:51:39.290893') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 21:51:39.290893"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-10-20 21:51:39.291736"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-10-20 21:51:39.298288"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.302159"], ["updated_at", "2014-10-20 21:51:39.302159"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 21:51:39.302727') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 21:51:39.302727"], ["editor_id", 13], ["updated_at", "2014-10-20 21:51:39.303584"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 13]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 21:51:39.307307"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.307307"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 12], ["updated_at", "2014-10-20 21:51:39.309162"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 21:51:39.309625') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 21:51:39.309625"], ["updated_at", "2014-10-20 21:51:39.310367"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.5ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------------------- Commontator::CommentsController: test_0013_must undelete if authorized and deleted ----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.315563"], ["updated_at", "2014-10-20 21:51:39.315563"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.316839"], ["updated_at", "2014-10-20 21:51:39.316839"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.318059"], ["updated_at", "2014-10-20 21:51:39.318059"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:39.320518"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.320518"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 21:51:39.321540') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 21:51:39.321540"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-10-20 21:51:39.322790"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-10-20 21:51:39.328889"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.331256"], ["updated_at", "2014-10-20 21:51:39.331256"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 21:51:39.333126"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.333126"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 21:51:39.333871') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 21:51:39.333871"], ["updated_at", "2014-10-20 21:51:39.334832"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 13], ["updated_at", "2014-10-20 21:51:39.338198"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 21:51:39.339572') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 21:51:39.339572"], ["editor_id", 12], ["updated_at", "2014-10-20 21:51:39.340467"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 13], ["updated_at", "2014-10-20 21:51:39.343758"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0014_won't upvote unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.346480"], ["updated_at", "2014-10-20 21:51:39.346480"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.347582"], ["updated_at", "2014-10-20 21:51:39.347582"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.348609"], ["updated_at", "2014-10-20 21:51:39.348609"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:39.350163"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.350163"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.359797"], ["updated_at", "2014-10-20 21:51:39.359797"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0015_must upvote if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.365809"], ["updated_at", "2014-10-20 21:51:39.365809"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.367011"], ["updated_at", "2014-10-20 21:51:39.367011"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.368042"], ["updated_at", "2014-10-20 21:51:39.368042"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:39.369744"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.369744"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.370664"], ["updated_at", "2014-10-20 21:51:39.370664"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-10-20 21:51:39.384786"], ["updated_at", "2014-10-20 21:51:39.384786"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 16ms (ActiveRecord: 0.7ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.2ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.2ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 7ms (ActiveRecord: 0.8ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-10-20 21:51:39.400141"], ["vote_flag", "f"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-10-20 21:51:39.406451"], ["vote_flag", "t"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------- Commontator::CommentsController: test_0016_won't downvote unless authorized ---------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.412557"], ["updated_at", "2014-10-20 21:51:39.412557"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.414539"], ["updated_at", "2014-10-20 21:51:39.414539"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.416039"], ["updated_at", "2014-10-20 21:51:39.416039"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:39.418609"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.418609"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.427260"], ["updated_at", "2014-10-20 21:51:39.427260"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------------- Commontator::CommentsController: test_0017_must downvote if authorized ----------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.433331"], ["updated_at", "2014-10-20 21:51:39.433331"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.435276"], ["updated_at", "2014-10-20 21:51:39.435276"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.436825"], ["updated_at", "2014-10-20 21:51:39.436825"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:39.439267"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.439267"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.440504"], ["updated_at", "2014-10-20 21:51:39.440504"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-10-20 21:51:39.445802"], ["updated_at", "2014-10-20 21:51:39.445802"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "f"], ["vote_weight", 1], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 8ms (ActiveRecord: 0.8ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-10-20 21:51:39.460728"], ["vote_flag", "t"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-10-20 21:51:39.466441"], ["vote_flag", "f"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0018_won't unvote unless authorized -------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.472333"], ["updated_at", "2014-10-20 21:51:39.472333"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.474419"], ["updated_at", "2014-10-20 21:51:39.474419"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.475932"], ["updated_at", "2014-10-20 21:51:39.475932"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:39.478453"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.478453"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-10-20 21:51:39.481212"], ["updated_at", "2014-10-20 21:51:39.481212"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 12], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.490547"], ["updated_at", "2014-10-20 21:51:39.490547"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0019_must unvote if authorized --------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.496580"], ["updated_at", "2014-10-20 21:51:39.496580"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.498515"], ["updated_at", "2014-10-20 21:51:39.498515"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.500058"], ["updated_at", "2014-10-20 21:51:39.500058"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:39.502517"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.502517"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.503744"], ["updated_at", "2014-10-20 21:51:39.503744"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-10-20 21:51:39.506328"], ["updated_at", "2014-10-20 21:51:39.506328"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 7ms (ActiveRecord: 0.9ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-10-20 21:51:39.525017"], ["updated_at", "2014-10-20 21:51:39.525017"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "f"], ["vote_weight", 1], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::CommentsController: test_0020_won't send mail if recipients empty ------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.536446"], ["updated_at", "2014-10-20 21:51:39.536446"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.537728"], ["updated_at", "2014-10-20 21:51:39.537728"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.538786"], ["updated_at", "2014-10-20 21:51:39.538786"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:39.540514"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.540514"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.541493"], ["updated_at", "2014-10-20 21:51:39.541493"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 21:51:39.545023"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.545023"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------- Commontator::CommentsController: test_0021_must send mail if recipients not empty ---------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.548358"], ["updated_at", "2014-10-20 21:51:39.548358"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.549434"], ["updated_at", "2014-10-20 21:51:39.549434"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 21:51:39.550376"], ["updated_at", "2014-10-20 21:51:39.550376"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 21:51:39.551905"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.551905"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 21:51:39.552829"], ["updated_at", "2014-10-20 21:51:39.552829"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 13], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 13) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 21:51:39.554751"], ["subscriber_id", 13], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.554751"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 21:51:39.558106"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 21:51:39.558106"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 13]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.4ms)  (0.4ms) rollback transaction  (1.0ms) CREATE TABLE "commontator_comments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "creator_type" varchar(255), "creator_id" integer, "editor_type" varchar(255), "editor_id" integer, "thread_id" integer NOT NULL, "body" text NOT NULL, "deleted_at" datetime, "cached_votes_up" integer DEFAULT 0, "cached_votes_down" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime)   (0.1ms) select sqlite_version(*)  (0.8ms) CREATE INDEX "index_commontator_comments_on_cached_votes_down" ON "commontator_comments" ("cached_votes_down")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'  (0.8ms) CREATE INDEX "index_commontator_comments_on_cached_votes_up" ON "commontator_comments" ("cached_votes_up")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.7ms) CREATE INDEX "index_commontator_comments_on_c_id_and_c_type_and_t_id" ON "commontator_comments" ("creator_id", "creator_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_comments_on_thread_id_and_created_at" ON "commontator_comments" ("thread_id", "created_at")  (0.8ms) CREATE TABLE "commontator_subscriptions" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "subscriber_type" varchar(255) NOT NULL, "subscriber_id" integer NOT NULL, "thread_id" integer NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE UNIQUE INDEX "index_commontator_subscriptions_on_s_id_and_s_type_and_t_id" ON "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_subscriptions_on_thread_id" ON "commontator_subscriptions" ("thread_id")  (0.8ms) CREATE TABLE "commontator_threads" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "commontable_type" varchar(255), "commontable_id" integer, "closed_at" datetime, "closer_type" varchar(255), "closer_id" integer, "created_at" datetime, "updated_at" datetime)   (0.7ms) CREATE UNIQUE INDEX "index_commontator_threads_on_c_id_and_c_type" ON "commontator_threads" ("commontable_id", "commontable_type")  (0.8ms) CREATE TABLE "dummy_models" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE TABLE "dummy_users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)  (0.8ms) CREATE TABLE "votes" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "votable_id" integer, "votable_type" varchar(255), "voter_id" integer, "voter_type" varchar(255), "vote_flag" boolean, "vote_scope" varchar(255), "vote_weight" integer, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE INDEX "index_votes_on_votable_id_and_votable_type_and_vote_scope" ON "votes" ("votable_id", "votable_type", "vote_scope")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index'   (0.9ms) CREATE INDEX "index_votes_on_voter_id_and_voter_type_and_vote_scope" ON "votes" ("voter_id", "voter_type", "vote_scope")  (0.8ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)   (0.8ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.1ms) SELECT version FROM "schema_migrations"  (0.8ms) INSERT INTO "schema_migrations" (version) VALUES ('3')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('1')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('2')  (0.8ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.0ms) begin transaction SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.209378"], ["updated_at", "2014-10-20 22:44:02.209378"]]  (1.3ms) commit transaction  (0.1ms) begin transaction --------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0001_won't subscribe unless authorized ---------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.217542"], ["updated_at", "2014-10-20 22:44:02.217542"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.219874"], ["updated_at", "2014-10-20 22:44:02.219874"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.220865"], ["updated_at", "2014-10-20 22:44:02.220865"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.3ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 22:44:02.242059"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-10-20 22:44:02.242059"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0002_must subscribe if authorized ----------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.248527"], ["updated_at", "2014-10-20 22:44:02.248527"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.249737"], ["updated_at", "2014-10-20 22:44:02.249737"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.250664"], ["updated_at", "2014-10-20 22:44:02.250664"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 22:44:02.254151"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-10-20 22:44:02.254151"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.0ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 22:44:02.259083"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-10-20 22:44:02.259083"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 22:44:02.263601"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-10-20 22:44:02.263601"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0003_won't unsubscribe unless authorized -----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.266453"], ["updated_at", "2014-10-20 22:44:02.266453"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.267559"], ["updated_at", "2014-10-20 22:44:02.267559"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.268471"], ["updated_at", "2014-10-20 22:44:02.268471"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 22:44:02.270338"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-10-20 22:44:02.270338"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.3ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::SubscriptionsController: test_0004_must unsubscribe if authorized ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.278023"], ["updated_at", "2014-10-20 22:44:02.278023"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.279061"], ["updated_at", "2014-10-20 22:44:02.279061"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.279940"], ["updated_at", "2014-10-20 22:44:02.279940"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 22:44:02.281814"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-10-20 22:44:02.281814"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 22:44:02.287051"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-10-20 22:44:02.287051"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 22:44:02.292862"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-10-20 22:44:02.292862"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 3]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::SharedHelper: test_0001_must show commontator thread -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.302436"], ["updated_at", "2014-10-20 22:44:02.302436"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.303416"], ["updated_at", "2014-10-20 22:44:02.303416"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 1]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/shared/_thread.html.erb (18.2ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------ Commontator::SubscriptionsMailer: test_0001_must create deliverable mail ------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.334345"], ["updated_at", "2014-10-20 22:44:02.334345"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.336178"], ["updated_at", "2014-10-20 22:44:02.336178"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.337465"], ["updated_at", "2014-10-20 22:44:02.337465"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.338442"], ["updated_at", "2014-10-20 22:44:02.338442"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 22:44:02.341250"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-10-20 22:44:02.341250"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 22:44:02.343061"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-10-20 22:44:02.343061"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.349780"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-10-20 22:44:02.349780"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/comments/_body.html.erb (2.3ms) Commontator::SubscriptionsMailer#comment_created: processed outbound mail in 14.7ms Sent mail to Undisclosed Recipients (4.5ms) Date: Mon, 20 Oct 2014 17:44:02 -0500 From: no-reply@dummy.com to: Undisclosed Recipients Message-ID: <544590325a50a_c313fef7582dbe8130e2@Dantes-MacBook-Pro.local.mail> Subject: Dummy User #1 posted a comment on DummyModel #2 Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit

Dummy User #1 commented on DummyModel #2:

Something

Click here to view all comments on DummyModel #2.

 (0.6ms) rollback transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.376926"], ["updated_at", "2014-10-20 22:44:02.376926"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.379329"], ["updated_at", "2014-10-20 22:44:02.379329"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.381218"], ["updated_at", "2014-10-20 22:44:02.381218"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 22:44:02.384558"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-10-20 22:44:02.384558"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-10-20 22:44:02.384558') [["thread_id", 1]]  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.389578"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-10-20 22:44:02.389578"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-10-20 22:44:02.384558') [["thread_id", 1]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction SQL (0.1ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-10-20 22:44:02.393276' WHERE "commontator_subscriptions"."id" = 1  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-10-20 22:44:02.393276') [["thread_id", 1]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.396644"], ["updated_at", "2014-10-20 22:44:02.396644"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.398365"], ["updated_at", "2014-10-20 22:44:02.398365"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 3], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.399873"], ["updated_at", "2014-10-20 22:44:02.399873"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 22:44:02.402650"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-10-20 22:44:02.402650"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.404132"], ["updated_at", "2014-10-20 22:44:02.404132"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 3], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 3) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 22:44:02.406684"], ["subscriber_id", 3], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-10-20 22:44:02.406684"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 3], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 3]]  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.410762"], ["updated_at", "2014-10-20 22:44:02.410762"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.412488"], ["updated_at", "2014-10-20 22:44:02.412488"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 4], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.413983"], ["updated_at", "2014-10-20 22:44:02.413983"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.415693"], ["updated_at", "2014-10-20 22:44:02.415693"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.417263"], ["updated_at", "2014-10-20 22:44:02.417263"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 5], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.418784"], ["updated_at", "2014-10-20 22:44:02.418784"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 5 AND "commontator_threads"."id" != 4 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.2ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 4 [["closed_at", "2014-10-20 22:44:02.420100"], ["closer_id", 5], ["closer_type", "DummyUser"], ["updated_at", "2014-10-20 22:44:02.421516"]]  (0.9ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 5 AND "commontator_threads"."id" != 4 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.2ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 4 [["closed_at", nil], ["updated_at", "2014-10-20 22:44:02.424349"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.426022"], ["updated_at", "2014-10-20 22:44:02.426022"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.427788"], ["updated_at", "2014-10-20 22:44:02.427788"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 6], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.429371"], ["updated_at", "2014-10-20 22:44:02.429371"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 5 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 6], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 5 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 6) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 22:44:02.432360"], ["subscriber_id", 6], ["subscriber_type", "DummyUser"], ["thread_id", 5], ["updated_at", "2014-10-20 22:44:02.432360"]]  (0.6ms) commit transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.433821"], ["updated_at", "2014-10-20 22:44:02.433821"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 5 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 7], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 5 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 7) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 22:44:02.436530"], ["subscriber_id", 7], ["subscriber_type", "DummyUser"], ["thread_id", 5], ["updated_at", "2014-10-20 22:44:02.436530"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 5]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 6]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 7]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.439403"], ["updated_at", "2014-10-20 22:44:02.439403"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.441012"], ["updated_at", "2014-10-20 22:44:02.441012"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 7], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.442482"], ["updated_at", "2014-10-20 22:44:02.442482"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 8 AND "commontator_comments"."thread_id" = 6 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.444925"], ["creator_id", 8], ["creator_type", "DummyUser"], ["thread_id", 6], ["updated_at", "2014-10-20 22:44:02.444925"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 8 AND "commontator_comments"."thread_id" = 6 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 22:44:02.447178"], ["creator_id", 8], ["creator_type", "DummyUser"], ["thread_id", 6], ["updated_at", "2014-10-20 22:44:02.447178"]]  (0.7ms) commit transaction Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 6]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY created_at ASC [["thread_id", 6]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.449907"], ["updated_at", "2014-10-20 22:44:02.449907"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.451573"], ["updated_at", "2014-10-20 22:44:02.451573"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 8], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.453167"], ["updated_at", "2014-10-20 22:44:02.453167"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 9 AND "commontator_comments"."thread_id" = 7 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.3ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.455497"], ["creator_id", 9], ["creator_type", "DummyUser"], ["thread_id", 7], ["updated_at", "2014-10-20 22:44:02.455497"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 8 AND "commontator_threads"."id" != 7 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 7 [["closed_at", "2014-10-20 22:44:02.457396"], ["closer_id", 9], ["closer_type", "DummyUser"], ["updated_at", "2014-10-20 22:44:02.458371"]]  (0.6ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 4 LIMIT 1 [["thread_id", 7]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 8]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 8], ["commontable_type", "DummyModel"]]  (0.0ms) begin transaction Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 7]] SQL (0.2ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "commontable_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 7 [["commontable_id", nil], ["commontable_type", nil], ["updated_at", "2014-10-20 22:44:02.462968"]] Commontator::Thread Exists (0.0ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 8 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 8], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.464070"], ["updated_at", "2014-10-20 22:44:02.464070"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 7]]  (0.7ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 4 LIMIT 1 [["thread_id", 7]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 8]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 8], ["commontable_type", "DummyModel"]] Commontator::Comment Exists (0.0ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 4 LIMIT 1 [["thread_id", 8]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.467951"], ["updated_at", "2014-10-20 22:44:02.467951"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.469642"], ["updated_at", "2014-10-20 22:44:02.469642"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.471132"], ["updated_at", "2014-10-20 22:44:02.471132"]]  (0.6ms) commit transaction  (0.0ms) begin transaction DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", nil]] SQL (0.1ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 9 [["commontable_id", nil], ["updated_at", "2014-10-20 22:44:02.473038"]]  (0.6ms) commit transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) begin transaction --------------------------------------------------------------- Commontator::Subscription: test_0001_must count unread comments ---------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.476266"], ["updated_at", "2014-10-20 22:44:02.476266"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.477296"], ["updated_at", "2014-10-20 22:44:02.477296"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.478208"], ["updated_at", "2014-10-20 22:44:02.478208"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 11) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 22:44:02.479694"], ["subscriber_id", 11], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.479694"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-10-20 22:44:02.479694') [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.481968"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.481968"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-10-20 22:44:02.479694') [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 22:44:02.485359"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.485359"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-10-20 22:44:02.479694') [["thread_id", 10]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-10-20 22:44:02.487824' WHERE "commontator_subscriptions"."id" = 6  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-10-20 22:44:02.487824') [["thread_id", 10]]  (0.8ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------------- Commontator::CommentsController: test_0001_won't get new unless authorized --------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.493151"], ["updated_at", "2014-10-20 22:44:02.493151"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.494470"], ["updated_at", "2014-10-20 22:44:02.494470"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.495797"], ["updated_at", "2014-10-20 22:44:02.495797"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.497932"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.497932"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------- Commontator::CommentsController: test_0002_must get new if authorized ---------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.506985"], ["updated_at", "2014-10-20 22:44:02.506985"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.508974"], ["updated_at", "2014-10-20 22:44:02.508974"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.510513"], ["updated_at", "2014-10-20 22:44:02.510513"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.513157"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.513157"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 1ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0003_won't create unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.528291"], ["updated_at", "2014-10-20 22:44:02.528291"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.529483"], ["updated_at", "2014-10-20 22:44:02.529483"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.530405"], ["updated_at", "2014-10-20 22:44:02.530405"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.532037"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.532037"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-10-20 22:44:02.535040"], ["updated_at", "2014-10-20 22:44:02.535880"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0004_must create if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.539191"], ["updated_at", "2014-10-20 22:44:02.539191"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.540367"], ["updated_at", "2014-10-20 22:44:02.540367"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.541448"], ["updated_at", "2014-10-20 22:44:02.541448"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.543088"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.543088"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 22:44:02.546400"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.546400"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Another thing"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Another thing' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Another thing"], ["created_at", "2014-10-20 22:44:02.550467"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.550467"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"And this too"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'And this too' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "And this too"], ["created_at", "2014-10-20 22:44:02.554237"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.554237"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.6ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0005_won't create if double posting -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.557708"], ["updated_at", "2014-10-20 22:44:02.557708"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.559029"], ["updated_at", "2014-10-20 22:44:02.559029"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.560194"], ["updated_at", "2014-10-20 22:44:02.560194"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.562613"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.562613"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something"}} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 22:44:02.571409"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.571409"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.2ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.4ms)  (0.6ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------- Commontator::CommentsController: test_0006_won't edit unless authorized -----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.579731"], ["updated_at", "2014-10-20 22:44:02.579731"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.580830"], ["updated_at", "2014-10-20 22:44:02.580830"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.581765"], ["updated_at", "2014-10-20 22:44:02.581765"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.583296"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.583296"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.587793"], ["updated_at", "2014-10-20 22:44:02.587793"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 22:44:02.591308"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.591308"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------ Commontator::CommentsController: test_0007_must edit if authorized ------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.595577"], ["updated_at", "2014-10-20 22:44:02.595577"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.596640"], ["updated_at", "2014-10-20 22:44:02.596640"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.597547"], ["updated_at", "2014-10-20 22:44:02.597547"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.599050"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.599050"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0008_won't update unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.610071"], ["updated_at", "2014-10-20 22:44:02.610071"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.611124"], ["updated_at", "2014-10-20 22:44:02.611124"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.612024"], ["updated_at", "2014-10-20 22:44:02.612024"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.613707"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.613707"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.618837"], ["updated_at", "2014-10-20 22:44:02.618837"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 22:44:02.622688"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.622688"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0009_must update if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.628292"], ["updated_at", "2014-10-20 22:44:02.628292"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.629438"], ["updated_at", "2014-10-20 22:44:02.629438"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.630359"], ["updated_at", "2014-10-20 22:44:02.630359"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.631922"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.631922"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["body", "Something else"], ["editor_id", 11], ["editor_type", "DummyUser"], ["updated_at", "2014-10-20 22:44:02.636292"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.4ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------------- Commontator::CommentsController: test_0010_won't delete unless authorized and not deleted -----------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.649201"], ["updated_at", "2014-10-20 22:44:02.649201"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.650496"], ["updated_at", "2014-10-20 22:44:02.650496"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.651523"], ["updated_at", "2014-10-20 22:44:02.651523"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.653307"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.653307"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 22:44:02.658683') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 22:44:02.658683"], ["editor_id", 11], ["editor_type", "DummyUser"], ["updated_at", "2014-10-20 22:44:02.660099"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 22:44:02.665812"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.665812"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-10-20 22:44:02.667490"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.4ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------------------ Commontator::CommentsController: test_0011_must delete if authorized and not deleted ------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.672909"], ["updated_at", "2014-10-20 22:44:02.672909"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.675115"], ["updated_at", "2014-10-20 22:44:02.675115"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.676576"], ["updated_at", "2014-10-20 22:44:02.676576"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.678999"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.678999"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 22:44:02.683509') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 22:44:02.683509"], ["editor_id", 11], ["editor_type", "DummyUser"], ["updated_at", "2014-10-20 22:44:02.684589"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 5ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.686333"], ["updated_at", "2014-10-20 22:44:02.686333"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 22:44:02.687732"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.687732"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-10-20 22:44:02.689200"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 22:44:02.691057') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 22:44:02.691057"], ["editor_id", 12], ["updated_at", "2014-10-20 22:44:02.691985"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 11], ["updated_at", "2014-10-20 22:44:02.694148"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 22:44:02.696182') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 22:44:02.696182"], ["editor_id", 12], ["updated_at", "2014-10-20 22:44:02.697139"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------------- Commontator::CommentsController: test_0012_won't undelete unless authorized and deleted ---------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.699762"], ["updated_at", "2014-10-20 22:44:02.699762"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.700852"], ["updated_at", "2014-10-20 22:44:02.700852"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.701771"], ["updated_at", "2014-10-20 22:44:02.701771"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.703376"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.703376"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 22:44:02.704041') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 22:44:02.704041"], ["editor_id", 11], ["editor_type", "DummyUser"], ["updated_at", "2014-10-20 22:44:02.704882"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-10-20 22:44:02.717717"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.722114"], ["updated_at", "2014-10-20 22:44:02.722114"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 22:44:02.722758') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 22:44:02.722758"], ["editor_id", 12], ["updated_at", "2014-10-20 22:44:02.723742"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 22:44:02.727781"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.727781"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 11], ["updated_at", "2014-10-20 22:44:02.729632"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 22:44:02.730109') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 22:44:02.730109"], ["updated_at", "2014-10-20 22:44:02.730877"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------------------- Commontator::CommentsController: test_0013_must undelete if authorized and deleted ----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.736083"], ["updated_at", "2014-10-20 22:44:02.736083"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.737187"], ["updated_at", "2014-10-20 22:44:02.737187"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.738096"], ["updated_at", "2014-10-20 22:44:02.738096"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.739651"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.739651"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 22:44:02.740286') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 22:44:02.740286"], ["editor_id", 11], ["editor_type", "DummyUser"], ["updated_at", "2014-10-20 22:44:02.741107"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-10-20 22:44:02.745945"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.747504"], ["updated_at", "2014-10-20 22:44:02.747504"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 22:44:02.749017"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.749017"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 22:44:02.749682') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 22:44:02.749682"], ["updated_at", "2014-10-20 22:44:02.750473"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 12], ["updated_at", "2014-10-20 22:44:02.753274"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 22:44:02.754448') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-10-20 22:44:02.754448"], ["editor_id", 11], ["updated_at", "2014-10-20 22:44:02.755221"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 12], ["updated_at", "2014-10-20 22:44:02.758143"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0014_won't upvote unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.760607"], ["updated_at", "2014-10-20 22:44:02.760607"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.761695"], ["updated_at", "2014-10-20 22:44:02.761695"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.762621"], ["updated_at", "2014-10-20 22:44:02.762621"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.764181"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.764181"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.773338"], ["updated_at", "2014-10-20 22:44:02.773338"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (1.4ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0015_must upvote if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.781339"], ["updated_at", "2014-10-20 22:44:02.781339"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.782749"], ["updated_at", "2014-10-20 22:44:02.782749"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.783732"], ["updated_at", "2014-10-20 22:44:02.783732"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.785811"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.785811"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.786823"], ["updated_at", "2014-10-20 22:44:02.786823"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-10-20 22:44:02.795176"], ["updated_at", "2014-10-20 22:44:02.795176"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 12], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 10ms (ActiveRecord: 0.7ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 5ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-10-20 22:44:02.808184"], ["vote_flag", "f"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-10-20 22:44:02.813671"], ["vote_flag", "t"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------- Commontator::CommentsController: test_0016_won't downvote unless authorized ---------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.819409"], ["updated_at", "2014-10-20 22:44:02.819409"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.821140"], ["updated_at", "2014-10-20 22:44:02.821140"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.822476"], ["updated_at", "2014-10-20 22:44:02.822476"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.825070"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.825070"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.833063"], ["updated_at", "2014-10-20 22:44:02.833063"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------- Commontator::CommentsController: test_0017_must downvote if authorized ----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.838649"], ["updated_at", "2014-10-20 22:44:02.838649"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.839780"], ["updated_at", "2014-10-20 22:44:02.839780"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.840704"], ["updated_at", "2014-10-20 22:44:02.840704"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.842291"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.842291"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.843152"], ["updated_at", "2014-10-20 22:44:02.843152"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-10-20 22:44:02.847278"], ["updated_at", "2014-10-20 22:44:02.847278"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "f"], ["vote_weight", 1], ["voter_id", 12], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.2ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-10-20 22:44:02.860841"], ["vote_flag", "t"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-10-20 22:44:02.866506"], ["vote_flag", "f"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0018_won't unvote unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.871818"], ["updated_at", "2014-10-20 22:44:02.871818"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.872994"], ["updated_at", "2014-10-20 22:44:02.872994"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.873946"], ["updated_at", "2014-10-20 22:44:02.873946"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.875649"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.875649"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 11 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-10-20 22:44:02.877795"], ["updated_at", "2014-10-20 22:44:02.877795"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 11], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.892553"], ["updated_at", "2014-10-20 22:44:02.892553"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0019_must unvote if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.898036"], ["updated_at", "2014-10-20 22:44:02.898036"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.899101"], ["updated_at", "2014-10-20 22:44:02.899101"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.900029"], ["updated_at", "2014-10-20 22:44:02.900029"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.901638"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.901638"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.902502"], ["updated_at", "2014-10-20 22:44:02.902502"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-10-20 22:44:02.904320"], ["updated_at", "2014-10-20 22:44:02.904320"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 12], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.2ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.9ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.1ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-10-20 22:44:02.921002"], ["updated_at", "2014-10-20 22:44:02.921002"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "f"], ["vote_weight", 1], ["voter_id", 12], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 2]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::CommentsController: test_0020_won't send mail if recipients empty ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.932603"], ["updated_at", "2014-10-20 22:44:02.932603"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.933732"], ["updated_at", "2014-10-20 22:44:02.933732"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.934691"], ["updated_at", "2014-10-20 22:44:02.934691"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.936331"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.936331"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.937492"], ["updated_at", "2014-10-20 22:44:02.937492"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 22:44:02.941311"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.941311"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.4ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------- Commontator::CommentsController: test_0021_must send mail if recipients not empty ---------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.944674"], ["updated_at", "2014-10-20 22:44:02.944674"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.945764"], ["updated_at", "2014-10-20 22:44:02.945764"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.946720"], ["updated_at", "2014-10-20 22:44:02.946720"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:02.948338"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.948338"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.949263"], ["updated_at", "2014-10-20 22:44:02.949263"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-10-20 22:44:02.951309"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.951309"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-10-20 22:44:02.954645"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:02.954645"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.4ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.958380"], ["updated_at", "2014-10-20 22:44:02.958380"]]  (0.6ms) commit transaction  (0.0ms) begin transaction ---------------------------------------------------------------------- Commontator::ThreadsController: test_0001_won't show unless authorized ----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.961348"], ["updated_at", "2014-10-20 22:44:02.961348"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.962401"], ["updated_at", "2014-10-20 22:44:02.962401"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.963308"], ["updated_at", "2014-10-20 22:44:02.963308"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.3ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------- Commontator::ThreadsController: test_0002_must show if authorized -----------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.968936"], ["updated_at", "2014-10-20 22:44:02.968936"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.970026"], ["updated_at", "2014-10-20 22:44:02.970026"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.970933"], ["updated_at", "2014-10-20 22:44:02.970933"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Load (0.2ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 10], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 10], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/10 Completed 302 Found in 2ms (ActiveRecord: 0.1ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 10], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/10 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------------------- Commontator::ThreadsController: test_0003_won't close unless authorized and open --------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.982155"], ["updated_at", "2014-10-20 22:44:02.982155"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.983261"], ["updated_at", "2014-10-20 22:44:02.983261"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.984170"], ["updated_at", "2014-10-20 22:44:02.984170"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-10-20 22:44:02.988816"], ["updated_at", "2014-10-20 22:44:02.989700"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------- Commontator::ThreadsController: test_0004_must close if authorized and open ---------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.993781"], ["updated_at", "2014-10-20 22:44:02.993781"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:02.994985"], ["updated_at", "2014-10-20 22:44:02.994985"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:02.995911"], ["updated_at", "2014-10-20 22:44:02.995911"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-10-20 22:44:02.998032"], ["closer_id", 12], ["closer_type", "DummyUser"], ["updated_at", "2014-10-20 22:44:02.998854"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", nil], ["updated_at", "2014-10-20 22:44:03.000933"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-10-20 22:44:03.002396"], ["updated_at", "2014-10-20 22:44:03.003204"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------- Commontator::ThreadsController: test_0005_won't reopen unless authorized and closed -----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:03.005848"], ["updated_at", "2014-10-20 22:44:03.005848"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:03.007549"], ["updated_at", "2014-10-20 22:44:03.007549"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:03.008564"], ["updated_at", "2014-10-20 22:44:03.008564"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-10-20 22:44:03.009164"], ["updated_at", "2014-10-20 22:44:03.009874"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", nil], ["updated_at", "2014-10-20 22:44:03.015711"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::ThreadsController: test_0006_must reopen if authorized and closed ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:03.019236"], ["updated_at", "2014-10-20 22:44:03.019236"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:03.020359"], ["updated_at", "2014-10-20 22:44:03.020359"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:03.021281"], ["updated_at", "2014-10-20 22:44:03.021281"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-10-20 22:44:03.021898"], ["updated_at", "2014-10-20 22:44:03.022564"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", nil], ["updated_at", "2014-10-20 22:44:03.025112"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-10-20 22:44:03.026379"], ["updated_at", "2014-10-20 22:44:03.026970"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", nil], ["updated_at", "2014-10-20 22:44:03.029230"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------- Commontator::Comment: test_0001_must be votable if acts_as_votable is installed -------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:03.032667"], ["updated_at", "2014-10-20 22:44:03.032667"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:03.033744"], ["updated_at", "2014-10-20 22:44:03.033744"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:03.034687"], ["updated_at", "2014-10-20 22:44:03.034687"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.3ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::Comment: test_0002_must know if it has been modified -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:03.036410"], ["updated_at", "2014-10-20 22:44:03.036410"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:03.037418"], ["updated_at", "2014-10-20 22:44:03.037418"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:03.038273"], ["updated_at", "2014-10-20 22:44:03.038273"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:03.039908"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:03.039908"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["body", "Something else"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-10-20 22:44:03.041457"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------- Commontator::Comment: test_0003_must know if it has been deleted ----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:03.043014"], ["updated_at", "2014-10-20 22:44:03.043014"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:03.044764"], ["updated_at", "2014-10-20 22:44:03.044764"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:03.045741"], ["updated_at", "2014-10-20 22:44:03.045741"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-10-20 22:44:03.046619') LIMIT 1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:03.047733"], ["updated_at", "2014-10-20 22:44:03.047733"]] SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "deleted_at", "editor_id", "editor_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:03.048246"], ["creator_id", 12], ["creator_type", "DummyUser"], ["deleted_at", "2014-10-20 22:44:03.046619"], ["editor_id", 13], ["editor_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:03.048246"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-10-20 22:44:03.049897"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------- Commontator::Comment: test_0004_must make proper timestamps -----------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:03.051420"], ["updated_at", "2014-10-20 22:44:03.051420"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:03.052432"], ["updated_at", "2014-10-20 22:44:03.052432"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-10-20 22:44:03.053418"], ["updated_at", "2014-10-20 22:44:03.053418"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-10-20 22:44:03.054983"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-10-20 22:44:03.054983"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-10-20 22:44:03.056605"], ["updated_at", "2014-10-20 22:44:03.056605"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["body", "Something else"], ["editor_id", 13], ["editor_type", "DummyUser"], ["updated_at", "2014-10-20 22:44:03.057958"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::ApplicationHelper: test_0001_must print javascript proc --------------------------------------------------------------------  (0.0ms) rollback transaction  (1.3ms) CREATE TABLE "commontator_comments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "creator_type" varchar(255), "creator_id" integer, "editor_type" varchar(255), "editor_id" integer, "thread_id" integer NOT NULL, "body" text NOT NULL, "deleted_at" datetime, "cached_votes_up" integer DEFAULT 0, "cached_votes_down" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime)   (0.1ms) select sqlite_version(*)  (0.8ms) CREATE INDEX "index_commontator_comments_on_cached_votes_down" ON "commontator_comments" ("cached_votes_down")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'  (0.8ms) CREATE INDEX "index_commontator_comments_on_cached_votes_up" ON "commontator_comments" ("cached_votes_up")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.7ms) CREATE INDEX "index_commontator_comments_on_c_id_and_c_type_and_t_id" ON "commontator_comments" ("creator_id", "creator_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_comments_on_thread_id_and_created_at" ON "commontator_comments" ("thread_id", "created_at")  (0.8ms) CREATE TABLE "commontator_subscriptions" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "subscriber_type" varchar(255) NOT NULL, "subscriber_id" integer NOT NULL, "thread_id" integer NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.9ms) CREATE UNIQUE INDEX "index_commontator_subscriptions_on_s_id_and_s_type_and_t_id" ON "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_subscriptions_on_thread_id" ON "commontator_subscriptions" ("thread_id")  (0.8ms) CREATE TABLE "commontator_threads" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "commontable_type" varchar(255), "commontable_id" integer, "closed_at" datetime, "closer_type" varchar(255), "closer_id" integer, "created_at" datetime, "updated_at" datetime)   (0.7ms) CREATE UNIQUE INDEX "index_commontator_threads_on_c_id_and_c_type" ON "commontator_threads" ("commontable_id", "commontable_type")  (0.8ms) CREATE TABLE "dummy_models" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE TABLE "dummy_users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)  (0.8ms) CREATE TABLE "votes" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "votable_id" integer, "votable_type" varchar(255), "voter_id" integer, "voter_type" varchar(255), "vote_flag" boolean, "vote_scope" varchar(255), "vote_weight" integer, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE INDEX "index_votes_on_votable_id_and_votable_type_and_vote_scope" ON "votes" ("votable_id", "votable_type", "vote_scope")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index'   (0.8ms) CREATE INDEX "index_votes_on_voter_id_and_voter_type_and_vote_scope" ON "votes" ("voter_id", "voter_type", "vote_scope")  (0.8ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)   (0.8ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.1ms) SELECT version FROM "schema_migrations"  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('3')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('1')  (0.6ms) INSERT INTO "schema_migrations" (version) VALUES ('2')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.1ms) begin transaction ------------------------------------------------------------------------------- Commontator::Comment: test_0001_must be votable if acts_as_votable is installed -------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.413209"], ["updated_at", "2014-11-17 16:56:51.413209"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.438140"], ["updated_at", "2014-11-17 16:56:51.438140"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.450929"], ["updated_at", "2014-11-17 16:56:51.450929"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.5ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------- Commontator::Comment: test_0002_must know if it has been modified -----------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.463864"], ["updated_at", "2014-11-17 16:56:51.463864"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.466380"], ["updated_at", "2014-11-17 16:56:51.466380"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.468935"], ["updated_at", "2014-11-17 16:56:51.468935"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:51.471710"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:56:51.471710"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["body", "Something else"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 16:56:51.474348"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.5ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------- Commontator::Comment: test_0003_must know if it has been deleted ----------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.477175"], ["updated_at", "2014-11-17 16:56:51.477175"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.479333"], ["updated_at", "2014-11-17 16:56:51.479333"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.481685"], ["updated_at", "2014-11-17 16:56:51.481685"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-11-17 16:56:51.482993') LIMIT 1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.484361"], ["updated_at", "2014-11-17 16:56:51.484361"]] SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "deleted_at", "editor_id", "editor_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:51.485024"], ["creator_id", 1], ["creator_type", "DummyUser"], ["deleted_at", "2014-11-17 16:56:51.482993"], ["editor_id", 2], ["editor_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:56:51.485024"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["updated_at", "2014-11-17 16:56:51.487139"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------- Commontator::Comment: test_0004_must make proper timestamps -----------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.488775"], ["updated_at", "2014-11-17 16:56:51.488775"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.490078"], ["updated_at", "2014-11-17 16:56:51.490078"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.491563"], ["updated_at", "2014-11-17 16:56:51.491563"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:51.493088"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:56:51.493088"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.494676"], ["updated_at", "2014-11-17 16:56:51.494676"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["body", "Something else"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 16:56:51.496019"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.3ms) rollback transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.499542"], ["updated_at", "2014-11-17 16:56:51.499542"]]  (0.6ms) commit transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::ApplicationHelper: test_0001_must print javascript proc --------------------------------------------------------------------  (0.0ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0001_won't subscribe unless authorized ---------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.505075"], ["updated_at", "2014-11-17 16:56:51.505075"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.506384"], ["updated_at", "2014-11-17 16:56:51.506384"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.507922"], ["updated_at", "2014-11-17 16:56:51.507922"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:56:51.526645"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:56:51.526645"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0002_must subscribe if authorized ----------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.532143"], ["updated_at", "2014-11-17 16:56:51.532143"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.533687"], ["updated_at", "2014-11-17 16:56:51.533687"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.535259"], ["updated_at", "2014-11-17 16:56:51.535259"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:56:51.538813"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:56:51.538813"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:56:51.544541"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:56:51.544541"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.4ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.0ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:56:51.549717"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:56:51.549717"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0003_won't unsubscribe unless authorized -----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.552696"], ["updated_at", "2014-11-17 16:56:51.552696"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.553947"], ["updated_at", "2014-11-17 16:56:51.553947"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.555479"], ["updated_at", "2014-11-17 16:56:51.555479"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:56:51.557559"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:56:51.557559"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::SubscriptionsController: test_0004_must unsubscribe if authorized ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.565609"], ["updated_at", "2014-11-17 16:56:51.565609"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.566850"], ["updated_at", "2014-11-17 16:56:51.566850"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.568345"], ["updated_at", "2014-11-17 16:56:51.568345"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:56:51.570331"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:56:51.570331"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 8ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:56:51.582075"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:56:51.582075"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:56:51.587115"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:56:51.587115"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 3]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.592502"], ["updated_at", "2014-11-17 16:56:51.592502"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.594748"], ["updated_at", "2014-11-17 16:56:51.594748"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.598148"], ["updated_at", "2014-11-17 16:56:51.598148"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.600035"], ["updated_at", "2014-11-17 16:56:51.600035"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.601488"], ["updated_at", "2014-11-17 16:56:51.601488"]]  (0.6ms) commit transaction  (0.0ms) begin transaction DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] SQL (0.1ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 2 [["commontable_id", nil], ["updated_at", "2014-11-17 16:56:51.603339"]]  (0.6ms) commit transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.605387"], ["updated_at", "2014-11-17 16:56:51.605387"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.607190"], ["updated_at", "2014-11-17 16:56:51.607190"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 3 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 3], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.608615"], ["updated_at", "2014-11-17 16:56:51.608615"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 3 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 3], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 3 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 3) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:56:51.611441"], ["subscriber_id", 3], ["subscriber_type", "DummyUser"], ["thread_id", 3], ["updated_at", "2014-11-17 16:56:51.611441"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.612954"], ["updated_at", "2014-11-17 16:56:51.612954"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 3 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 4], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 3 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 4) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:56:51.615475"], ["subscriber_id", 4], ["subscriber_type", "DummyUser"], ["thread_id", 3], ["updated_at", "2014-11-17 16:56:51.615475"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 3 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 3], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 3]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 3]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 3 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 4], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 3]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 4]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.619754"], ["updated_at", "2014-11-17 16:56:51.619754"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.621540"], ["updated_at", "2014-11-17 16:56:51.621540"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 4]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 4 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 4], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.622969"], ["updated_at", "2014-11-17 16:56:51.622969"]]  (0.8ms) commit transaction  (0.1ms) begin transaction Commontator::Comment Exists (0.2ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 5 AND "commontator_comments"."thread_id" = 4 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.3ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:51.626427"], ["creator_id", 5], ["creator_type", "DummyUser"], ["thread_id", 4], ["updated_at", "2014-11-17 16:56:51.626427"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 4 AND "commontator_threads"."id" != 4 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.3ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 4 [["closed_at", "2014-11-17 16:56:51.628355"], ["closer_id", 5], ["closer_type", "DummyUser"], ["updated_at", "2014-11-17 16:56:51.629172"]]  (0.6ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 1 LIMIT 1 [["thread_id", 4]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 4]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 4], ["commontable_type", "DummyModel"]]  (0.0ms) begin transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 4]] SQL (0.2ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "commontable_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 4 [["commontable_id", nil], ["commontable_type", nil], ["updated_at", "2014-11-17 16:56:51.635040"]] Commontator::Thread Exists (0.0ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 4 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 4], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.636257"], ["updated_at", "2014-11-17 16:56:51.636257"]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 4]]  (0.6ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 1 LIMIT 1 [["thread_id", 4]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 4]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 4], ["commontable_type", "DummyModel"]] Commontator::Comment Exists (0.0ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 1 LIMIT 1 [["thread_id", 5]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.640777"], ["updated_at", "2014-11-17 16:56:51.640777"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.642576"], ["updated_at", "2014-11-17 16:56:51.642576"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 5 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 5], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.644013"], ["updated_at", "2014-11-17 16:56:51.644013"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 6 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 6], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 6 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 6) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:56:51.646780"], ["subscriber_id", 6], ["subscriber_type", "DummyUser"], ["thread_id", 6], ["updated_at", "2014-11-17 16:56:51.646780"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.648289"], ["updated_at", "2014-11-17 16:56:51.648289"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 6 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 7], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 6 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 7) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:56:51.650856"], ["subscriber_id", 7], ["subscriber_type", "DummyUser"], ["thread_id", 6], ["updated_at", "2014-11-17 16:56:51.650856"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 6]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 6]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 7]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.653759"], ["updated_at", "2014-11-17 16:56:51.653759"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.655562"], ["updated_at", "2014-11-17 16:56:51.655562"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 6 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 6], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.657010"], ["updated_at", "2014-11-17 16:56:51.657010"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 7 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 8], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 7 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 8) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:56:51.659687"], ["subscriber_id", 8], ["subscriber_type", "DummyUser"], ["thread_id", 7], ["updated_at", "2014-11-17 16:56:51.659687"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 7 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 8], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 7]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 6]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 16:56:51.659687') [["thread_id", 7]]  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 8 AND "commontator_comments"."thread_id" = 7 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:51.664769"], ["creator_id", 8], ["creator_type", "DummyUser"], ["thread_id", 7], ["updated_at", "2014-11-17 16:56:51.664769"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 7]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 6]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 16:56:51.659687') [["thread_id", 7]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 7 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 8], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction SQL (0.1ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-11-17 16:56:51.668568' WHERE "commontator_subscriptions"."id" = 5  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 7]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 6]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 16:56:51.668568') [["thread_id", 7]]  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.673149"], ["updated_at", "2014-11-17 16:56:51.673149"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.675823"], ["updated_at", "2014-11-17 16:56:51.675823"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 7]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 7 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 7], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.678049"], ["updated_at", "2014-11-17 16:56:51.678049"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.679911"], ["updated_at", "2014-11-17 16:56:51.679911"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.681796"], ["updated_at", "2014-11-17 16:56:51.681796"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 8]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 8 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 8], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.683279"], ["updated_at", "2014-11-17 16:56:51.683279"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 10 AND "commontator_comments"."thread_id" = 9 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:51.685564"], ["creator_id", 10], ["creator_type", "DummyUser"], ["thread_id", 9], ["updated_at", "2014-11-17 16:56:51.685564"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 10 AND "commontator_comments"."thread_id" = 9 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:56:51.687822"], ["creator_id", 10], ["creator_type", "DummyUser"], ["thread_id", 9], ["updated_at", "2014-11-17 16:56:51.687822"]]  (0.6ms) commit transaction Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 9]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY created_at ASC [["thread_id", 9]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.690532"], ["updated_at", "2014-11-17 16:56:51.690532"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.692284"], ["updated_at", "2014-11-17 16:56:51.692284"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.693800"], ["updated_at", "2014-11-17 16:56:51.693800"]]  (0.6ms) commit transaction  (0.1ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.2ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-11-17 16:56:51.695119"], ["closer_id", 11], ["closer_type", "DummyUser"], ["updated_at", "2014-11-17 16:56:51.696019"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", nil], ["updated_at", "2014-11-17 16:56:51.697999"]]  (0.6ms) commit transaction  (0.0ms) begin transaction ------------------------------------------------------------------------ Commontator::SubscriptionsMailer: test_0001_must create deliverable mail ------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.703514"], ["updated_at", "2014-11-17 16:56:51.703514"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.705296"], ["updated_at", "2014-11-17 16:56:51.705296"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.706908"], ["updated_at", "2014-11-17 16:56:51.706908"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.707804"], ["updated_at", "2014-11-17 16:56:51.707804"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 11 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:56:51.709972"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:51.709972"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 13], ["subscriber_type", "DummyUser"]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 11 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 13) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:56:51.711851"], ["subscriber_id", 13], ["subscriber_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:51.711851"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:51.713420"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:51.713420"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 11]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 13]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/comments/_body.html.erb (3.5ms) Commontator::SubscriptionsMailer#comment_created: processed outbound mail in 25.6ms Sent mail to Undisclosed Recipients (6.4ms) Date: Mon, 17 Nov 2014 10:56:51 -0600 From: no-reply@dummy.com to: Undisclosed Recipients Message-ID: <546a28d3b678d_5aba3fe29a02dbec75876@Dantes-MacBook-Pro.local.mail> Subject: Dummy User #12 posted a comment on DummyModel #10 Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit

Dummy User #12 commented on DummyModel #10:

Something

Click here to view all comments on DummyModel #10.

 (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------- Commontator::ThreadsController: test_0001_won't show unless authorized ----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.755409"], ["updated_at", "2014-11-17 16:56:51.755409"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.757068"], ["updated_at", "2014-11-17 16:56:51.757068"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.758757"], ["updated_at", "2014-11-17 16:56:51.758757"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.3ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------- Commontator::ThreadsController: test_0002_must show if authorized -----------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.764933"], ["updated_at", "2014-11-17 16:56:51.764933"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.767244"], ["updated_at", "2014-11-17 16:56:51.767244"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.769617"], ["updated_at", "2014-11-17 16:56:51.769617"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 10], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/10 Completed 302 Found in 4ms (ActiveRecord: 0.2ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 10], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 10], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------------------- Commontator::ThreadsController: test_0003_won't close unless authorized and open --------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.782943"], ["updated_at", "2014-11-17 16:56:51.782943"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.785229"], ["updated_at", "2014-11-17 16:56:51.785229"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.787600"], ["updated_at", "2014-11-17 16:56:51.787600"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"11"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 11 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 11 [["closed_at", "2014-11-17 16:56:51.798821"], ["updated_at", "2014-11-17 16:56:51.799577"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------- Commontator::ThreadsController: test_0004_must close if authorized and open ---------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.803345"], ["updated_at", "2014-11-17 16:56:51.803345"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.804653"], ["updated_at", "2014-11-17 16:56:51.804653"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.806128"], ["updated_at", "2014-11-17 16:56:51.806128"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 11 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 11 [["closed_at", "2014-11-17 16:56:51.808084"], ["closer_id", 12], ["closer_type", "DummyUser"], ["updated_at", "2014-11-17 16:56:51.808797"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 2ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 11 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 11 [["closed_at", nil], ["updated_at", "2014-11-17 16:56:51.810779"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 11 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 11 [["closed_at", "2014-11-17 16:56:51.812227"], ["updated_at", "2014-11-17 16:56:51.812999"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------- Commontator::ThreadsController: test_0005_won't reopen unless authorized and closed -----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.815388"], ["updated_at", "2014-11-17 16:56:51.815388"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.816672"], ["updated_at", "2014-11-17 16:56:51.816672"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.818209"], ["updated_at", "2014-11-17 16:56:51.818209"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 11 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 11 [["closed_at", "2014-11-17 16:56:51.818816"], ["updated_at", "2014-11-17 16:56:51.819398"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"11"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 11 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 11 [["closed_at", nil], ["updated_at", "2014-11-17 16:56:51.825070"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.3ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::ThreadsController: test_0006_must reopen if authorized and closed ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.828597"], ["updated_at", "2014-11-17 16:56:51.828597"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.829776"], ["updated_at", "2014-11-17 16:56:51.829776"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.831209"], ["updated_at", "2014-11-17 16:56:51.831209"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 11 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 11 [["closed_at", "2014-11-17 16:56:51.831814"], ["updated_at", "2014-11-17 16:56:51.832385"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 11 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 11 [["closed_at", nil], ["updated_at", "2014-11-17 16:56:51.834942"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.1ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 11 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 11 [["closed_at", "2014-11-17 16:56:51.836157"], ["updated_at", "2014-11-17 16:56:51.836766"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 11 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 11 [["closed_at", nil], ["updated_at", "2014-11-17 16:56:51.839195"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------------- Commontator::CommentsController: test_0001_won't get new unless authorized --------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.842465"], ["updated_at", "2014-11-17 16:56:51.842465"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.844477"], ["updated_at", "2014-11-17 16:56:51.844477"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.846203"], ["updated_at", "2014-11-17 16:56:51.846203"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:51.847912"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:51.847912"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"11"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------- Commontator::CommentsController: test_0002_must get new if authorized ---------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.853210"], ["updated_at", "2014-11-17 16:56:51.853210"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.854584"], ["updated_at", "2014-11-17 16:56:51.854584"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.856081"], ["updated_at", "2014-11-17 16:56:51.856081"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:51.857920"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:51.857920"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 1ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 1ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0003_won't create unless authorized -------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.866817"], ["updated_at", "2014-11-17 16:56:51.866817"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.868987"], ["updated_at", "2014-11-17 16:56:51.868987"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.871353"], ["updated_at", "2014-11-17 16:56:51.871353"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:51.873691"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:51.873691"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 11 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 11 [["closed_at", "2014-11-17 16:56:51.877371"], ["updated_at", "2014-11-17 16:56:51.878256"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0004_must create if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.882407"], ["updated_at", "2014-11-17 16:56:51.882407"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.883796"], ["updated_at", "2014-11-17 16:56:51.883796"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.885348"], ["updated_at", "2014-11-17 16:56:51.885348"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:51.886958"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:51.886958"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:56:51.890330"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:51.890330"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Another thing"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Another thing' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Another thing"], ["created_at", "2014-11-17 16:56:51.894673"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:51.894673"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"And this too"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'And this too' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "And this too"], ["created_at", "2014-11-17 16:56:51.898695"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:51.898695"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.3ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0005_won't create if double posting -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.901769"], ["updated_at", "2014-11-17 16:56:51.901769"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.902979"], ["updated_at", "2014-11-17 16:56:51.902979"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.904458"], ["updated_at", "2014-11-17 16:56:51.904458"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:51.906090"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:51.906090"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:56:51.913021"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:51.913021"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------- Commontator::CommentsController: test_0006_won't edit unless authorized -----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.919582"], ["updated_at", "2014-11-17 16:56:51.919582"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.920863"], ["updated_at", "2014-11-17 16:56:51.920863"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.922411"], ["updated_at", "2014-11-17 16:56:51.922411"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:51.923975"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:51.923975"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.2ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 4ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.929685"], ["updated_at", "2014-11-17 16:56:51.929685"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:56:51.933552"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:51.933552"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------ Commontator::CommentsController: test_0007_must edit if authorized ------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.938049"], ["updated_at", "2014-11-17 16:56:51.938049"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.939264"], ["updated_at", "2014-11-17 16:56:51.939264"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.940755"], ["updated_at", "2014-11-17 16:56:51.940755"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:51.942334"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:51.942334"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0008_won't update unless authorized -------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.954467"], ["updated_at", "2014-11-17 16:56:51.954467"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.956822"], ["updated_at", "2014-11-17 16:56:51.956822"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.959384"], ["updated_at", "2014-11-17 16:56:51.959384"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:51.962047"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:51.962047"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.968734"], ["updated_at", "2014-11-17 16:56:51.968734"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 6ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:56:51.977812"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:51.977812"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.5ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0009_must update if authorized --------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.983559"], ["updated_at", "2014-11-17 16:56:51.983559"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:51.985858"], ["updated_at", "2014-11-17 16:56:51.985858"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:51.988289"], ["updated_at", "2014-11-17 16:56:51.988289"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:51.990695"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:51.990695"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["body", "Something else"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 16:56:51.996776"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 5ms (ActiveRecord: 0.5ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------------- Commontator::CommentsController: test_0010_won't delete unless authorized and not deleted -----------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.008076"], ["updated_at", "2014-11-17 16:56:52.008076"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.009352"], ["updated_at", "2014-11-17 16:56:52.009352"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:52.010849"], ["updated_at", "2014-11-17 16:56:52.010849"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:52.012420"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:52.012420"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-11-17 16:56:52.017123') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 16:56:52.017123"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 16:56:52.018517"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:56:52.023788"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:52.023788"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-11-17 16:56:52.025240"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------------ Commontator::CommentsController: test_0011_must delete if authorized and not deleted ------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.029938"], ["updated_at", "2014-11-17 16:56:52.029938"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.031149"], ["updated_at", "2014-11-17 16:56:52.031149"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:52.032683"], ["updated_at", "2014-11-17 16:56:52.032683"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:52.034264"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:52.034264"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-11-17 16:56:52.037750') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 16:56:52.037750"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 16:56:52.038672"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 4ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.040347"], ["updated_at", "2014-11-17 16:56:52.040347"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:56:52.041809"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:52.041809"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-11-17 16:56:52.043449"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-11-17 16:56:52.045545') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 16:56:52.045545"], ["editor_id", 13], ["updated_at", "2014-11-17 16:56:52.046638"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 4ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 12], ["updated_at", "2014-11-17 16:56:52.049359"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-11-17 16:56:52.051584') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 16:56:52.051584"], ["editor_id", 13], ["updated_at", "2014-11-17 16:56:52.052483"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------------------- Commontator::CommentsController: test_0012_won't undelete unless authorized and deleted ---------------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.055683"], ["updated_at", "2014-11-17 16:56:52.055683"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.057313"], ["updated_at", "2014-11-17 16:56:52.057313"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:52.059293"], ["updated_at", "2014-11-17 16:56:52.059293"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:52.061792"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:52.061792"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-11-17 16:56:52.062714') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 16:56:52.062714"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 16:56:52.063888"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.3ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-11-17 16:56:52.071125"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.075123"], ["updated_at", "2014-11-17 16:56:52.075123"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-11-17 16:56:52.075663') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 16:56:52.075663"], ["editor_id", 13], ["updated_at", "2014-11-17 16:56:52.076501"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 13]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:56:52.080399"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:52.080399"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 12], ["updated_at", "2014-11-17 16:56:52.082232"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-11-17 16:56:52.082707') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 16:56:52.082707"], ["updated_at", "2014-11-17 16:56:52.083469"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.5ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------------------------- Commontator::CommentsController: test_0013_must undelete if authorized and deleted ----------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.089186"], ["updated_at", "2014-11-17 16:56:52.089186"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.091562"], ["updated_at", "2014-11-17 16:56:52.091562"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:52.094338"], ["updated_at", "2014-11-17 16:56:52.094338"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:52.096788"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:52.096788"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-11-17 16:56:52.097728') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 16:56:52.097728"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 16:56:52.098815"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-11-17 16:56:52.104285"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 5ms (ActiveRecord: 0.5ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.105904"], ["updated_at", "2014-11-17 16:56:52.105904"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:56:52.107460"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:52.107460"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-11-17 16:56:52.108114') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 16:56:52.108114"], ["updated_at", "2014-11-17 16:56:52.108940"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 13], ["updated_at", "2014-11-17 16:56:52.112020"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-11-17 16:56:52.113267') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 16:56:52.113267"], ["editor_id", 12], ["updated_at", "2014-11-17 16:56:52.114105"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 13], ["updated_at", "2014-11-17 16:56:52.117067"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0014_won't upvote unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.119652"], ["updated_at", "2014-11-17 16:56:52.119652"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.120993"], ["updated_at", "2014-11-17 16:56:52.120993"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:52.122506"], ["updated_at", "2014-11-17 16:56:52.122506"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:52.124058"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:52.124058"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.133285"], ["updated_at", "2014-11-17 16:56:52.133285"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0015_must upvote if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.138786"], ["updated_at", "2014-11-17 16:56:52.138786"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.140111"], ["updated_at", "2014-11-17 16:56:52.140111"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:52.141684"], ["updated_at", "2014-11-17 16:56:52.141684"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:52.143346"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:52.143346"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.144250"], ["updated_at", "2014-11-17 16:56:52.144250"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:56:52.157907"], ["updated_at", "2014-11-17 16:56:52.157907"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 16ms (ActiveRecord: 0.7ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 7ms (ActiveRecord: 0.7ms)  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-11-17 16:56:52.175819"], ["vote_flag", "f"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-11-17 16:56:52.182916"], ["vote_flag", "t"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------- Commontator::CommentsController: test_0016_won't downvote unless authorized ---------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.188967"], ["updated_at", "2014-11-17 16:56:52.188967"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.191286"], ["updated_at", "2014-11-17 16:56:52.191286"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:52.193708"], ["updated_at", "2014-11-17 16:56:52.193708"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:52.196103"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:52.196103"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.204352"], ["updated_at", "2014-11-17 16:56:52.204352"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------- Commontator::CommentsController: test_0017_must downvote if authorized ----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.209750"], ["updated_at", "2014-11-17 16:56:52.209750"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.210945"], ["updated_at", "2014-11-17 16:56:52.210945"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:52.212433"], ["updated_at", "2014-11-17 16:56:52.212433"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:52.214077"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:52.214077"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.214939"], ["updated_at", "2014-11-17 16:56:52.214939"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:56:52.219076"], ["updated_at", "2014-11-17 16:56:52.219076"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "f"], ["vote_weight", 1], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 6ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-11-17 16:56:52.232788"], ["vote_flag", "t"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-11-17 16:56:52.238534"], ["vote_flag", "f"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0018_won't unvote unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.243674"], ["updated_at", "2014-11-17 16:56:52.243674"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.244969"], ["updated_at", "2014-11-17 16:56:52.244969"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:52.246509"], ["updated_at", "2014-11-17 16:56:52.246509"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:52.248165"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:52.248165"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:56:52.250228"], ["updated_at", "2014-11-17 16:56:52.250228"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 12], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.259425"], ["updated_at", "2014-11-17 16:56:52.259425"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0019_must unvote if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.264760"], ["updated_at", "2014-11-17 16:56:52.264760"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.265985"], ["updated_at", "2014-11-17 16:56:52.265985"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:52.267479"], ["updated_at", "2014-11-17 16:56:52.267479"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:52.269128"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:52.269128"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.270000"], ["updated_at", "2014-11-17 16:56:52.270000"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:56:52.271846"], ["updated_at", "2014-11-17 16:56:52.271846"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 7ms (ActiveRecord: 0.7ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:56:52.289347"], ["updated_at", "2014-11-17 16:56:52.289347"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "f"], ["vote_weight", 1], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 6ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::CommentsController: test_0020_won't send mail if recipients empty ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.301109"], ["updated_at", "2014-11-17 16:56:52.301109"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.302526"], ["updated_at", "2014-11-17 16:56:52.302526"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:52.304166"], ["updated_at", "2014-11-17 16:56:52.304166"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:52.305803"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:52.305803"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.306751"], ["updated_at", "2014-11-17 16:56:52.306751"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:56:52.310100"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:52.310100"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 4ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------- Commontator::CommentsController: test_0021_must send mail if recipients not empty ---------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.313224"], ["updated_at", "2014-11-17 16:56:52.313224"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.314466"], ["updated_at", "2014-11-17 16:56:52.314466"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:52.316099"], ["updated_at", "2014-11-17 16:56:52.316099"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:52.317689"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:52.317689"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.318616"], ["updated_at", "2014-11-17 16:56:52.318616"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 13], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 11 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 13) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:56:52.320670"], ["subscriber_id", 13], ["subscriber_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:52.320670"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:56:52.324040"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:52.324040"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 11]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 13]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 4ms (ActiveRecord: 0.4ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------- Commontator::Subscription: test_0001_must count unread comments ---------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.328101"], ["updated_at", "2014-11-17 16:56:52.328101"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.334630"], ["updated_at", "2014-11-17 16:56:52.334630"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:52.336536"], ["updated_at", "2014-11-17 16:56:52.336536"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 11 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:56:52.338152"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:52.338152"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 16:56:52.338152') [["thread_id", 11]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:56:52.340535"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:52.340535"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 16:56:52.338152') [["thread_id", 11]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:56:52.344578"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:56:52.344578"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 16:56:52.338152') [["thread_id", 11]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-11-17 16:56:52.347187' WHERE "commontator_subscriptions"."id" = 6  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 16:56:52.347187') [["thread_id", 11]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::SharedHelper: test_0001_must show commontator thread -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:56:52.355730"], ["updated_at", "2014-11-17 16:56:52.355730"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:56:52.357467"], ["updated_at", "2014-11-17 16:56:52.357467"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 11]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/shared/_thread.html.erb (8.3ms)  (0.2ms) rollback transaction  (1.9ms) CREATE TABLE "commontator_comments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "creator_type" varchar(255), "creator_id" integer, "editor_type" varchar(255), "editor_id" integer, "thread_id" integer NOT NULL, "body" text NOT NULL, "deleted_at" datetime, "cached_votes_up" integer DEFAULT 0, "cached_votes_down" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime)   (0.1ms) select sqlite_version(*)  (1.0ms) CREATE INDEX "index_commontator_comments_on_cached_votes_down" ON "commontator_comments" ("cached_votes_down")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'  (0.9ms) CREATE INDEX "index_commontator_comments_on_cached_votes_up" ON "commontator_comments" ("cached_votes_up")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.9ms) CREATE INDEX "index_commontator_comments_on_c_id_and_c_type_and_t_id" ON "commontator_comments" ("creator_id", "creator_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.9ms) CREATE INDEX "index_commontator_comments_on_thread_id_and_created_at" ON "commontator_comments" ("thread_id", "created_at")  (0.9ms) CREATE TABLE "commontator_subscriptions" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "subscriber_type" varchar(255) NOT NULL, "subscriber_id" integer NOT NULL, "thread_id" integer NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE UNIQUE INDEX "index_commontator_subscriptions_on_s_id_and_s_type_and_t_id" ON "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_subscriptions_on_thread_id" ON "commontator_subscriptions" ("thread_id")  (0.7ms) CREATE TABLE "commontator_threads" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "commontable_type" varchar(255), "commontable_id" integer, "closed_at" datetime, "closer_type" varchar(255), "closer_id" integer, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE UNIQUE INDEX "index_commontator_threads_on_c_id_and_c_type" ON "commontator_threads" ("commontable_id", "commontable_type")  (0.8ms) CREATE TABLE "dummy_models" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.7ms) CREATE TABLE "dummy_users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)  (0.8ms) CREATE TABLE "votes" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "votable_id" integer, "votable_type" varchar(255), "voter_id" integer, "voter_type" varchar(255), "vote_flag" boolean, "vote_scope" varchar(255), "vote_weight" integer, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE INDEX "index_votes_on_votable_id_and_votable_type_and_vote_scope" ON "votes" ("votable_id", "votable_type", "vote_scope")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index'   (0.8ms) CREATE INDEX "index_votes_on_voter_id_and_voter_type_and_vote_scope" ON "votes" ("voter_id", "voter_type", "vote_scope")  (0.7ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)   (0.8ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.1ms) SELECT version FROM "schema_migrations"  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('3')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('1')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('2')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.0ms) begin transaction SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.179954"], ["updated_at", "2014-11-17 16:57:33.179954"]]  (1.3ms) commit transaction  (0.1ms) begin transaction ------------------------------------------------------------------------------- Commontator::Comment: test_0001_must be votable if acts_as_votable is installed -------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.189323"], ["updated_at", "2014-11-17 16:57:33.189323"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.201949"], ["updated_at", "2014-11-17 16:57:33.201949"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.210130"], ["updated_at", "2014-11-17 16:57:33.210130"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::Comment: test_0002_must know if it has been modified -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.221707"], ["updated_at", "2014-11-17 16:57:33.221707"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.223067"], ["updated_at", "2014-11-17 16:57:33.223067"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.224549"], ["updated_at", "2014-11-17 16:57:33.224549"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.226397"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.226397"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["body", "Something else"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 16:57:33.228399"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------- Commontator::Comment: test_0003_must know if it has been deleted ----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.230215"], ["updated_at", "2014-11-17 16:57:33.230215"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.231487"], ["updated_at", "2014-11-17 16:57:33.231487"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.233006"], ["updated_at", "2014-11-17 16:57:33.233006"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-11-17 16:57:33.233876') LIMIT 1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.234827"], ["updated_at", "2014-11-17 16:57:33.234827"]] SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "deleted_at", "editor_id", "editor_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.235282"], ["creator_id", 2], ["creator_type", "DummyUser"], ["deleted_at", "2014-11-17 16:57:33.233876"], ["editor_id", 3], ["editor_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.235282"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["updated_at", "2014-11-17 16:57:33.236869"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.3ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------- Commontator::Comment: test_0004_must make proper timestamps -----------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.238270"], ["updated_at", "2014-11-17 16:57:33.238270"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.239392"], ["updated_at", "2014-11-17 16:57:33.239392"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.240765"], ["updated_at", "2014-11-17 16:57:33.240765"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.242253"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.242253"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.243886"], ["updated_at", "2014-11-17 16:57:33.243886"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["body", "Something else"], ["editor_id", 3], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 16:57:33.245141"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------- Commontator::ThreadsController: test_0001_won't show unless authorized ----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.252100"], ["updated_at", "2014-11-17 16:57:33.252100"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.253573"], ["updated_at", "2014-11-17 16:57:33.253573"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.255195"], ["updated_at", "2014-11-17 16:57:33.255195"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.2ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.3ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::ThreadsController: test_0002_must show if authorized -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.261815"], ["updated_at", "2014-11-17 16:57:33.261815"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.263985"], ["updated_at", "2014-11-17 16:57:33.263985"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.265711"], ["updated_at", "2014-11-17 16:57:33.265711"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 1], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/1 Completed 302 Found in 9ms (ActiveRecord: 0.5ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 1], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 1], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------------------- Commontator::ThreadsController: test_0003_won't close unless authorized and open --------------------------------------------------------------------------------  (0.3ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.283301"], ["updated_at", "2014-11-17 16:57:33.283301"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.284597"], ["updated_at", "2014-11-17 16:57:33.284597"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.286071"], ["updated_at", "2014-11-17 16:57:33.286071"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-11-17 16:57:33.290526"], ["updated_at", "2014-11-17 16:57:33.291131"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.3ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------- Commontator::ThreadsController: test_0004_must close if authorized and open ---------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.295288"], ["updated_at", "2014-11-17 16:57:33.295288"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.296696"], ["updated_at", "2014-11-17 16:57:33.296696"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.2ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.299115"], ["updated_at", "2014-11-17 16:57:33.299115"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-11-17 16:57:33.301589"], ["closer_id", 2], ["closer_type", "DummyUser"], ["updated_at", "2014-11-17 16:57:33.302378"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-11-17 16:57:33.304567"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-11-17 16:57:33.306046"], ["updated_at", "2014-11-17 16:57:33.306717"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------- Commontator::ThreadsController: test_0005_won't reopen unless authorized and closed -----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.309115"], ["updated_at", "2014-11-17 16:57:33.309115"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.310317"], ["updated_at", "2014-11-17 16:57:33.310317"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.0ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.311668"], ["updated_at", "2014-11-17 16:57:33.311668"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.0ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-11-17 16:57:33.312267"], ["updated_at", "2014-11-17 16:57:33.312824"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-11-17 16:57:33.324734"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::ThreadsController: test_0006_must reopen if authorized and closed ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.328734"], ["updated_at", "2014-11-17 16:57:33.328734"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.330000"], ["updated_at", "2014-11-17 16:57:33.330000"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.331425"], ["updated_at", "2014-11-17 16:57:33.331425"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.0ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-11-17 16:57:33.332001"], ["updated_at", "2014-11-17 16:57:33.332547"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-11-17 16:57:33.335032"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-11-17 16:57:33.336265"], ["updated_at", "2014-11-17 16:57:33.336835"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.0ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-11-17 16:57:33.339007"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.3ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------------- Commontator::CommentsController: test_0001_won't get new unless authorized --------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.342028"], ["updated_at", "2014-11-17 16:57:33.342028"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.343298"], ["updated_at", "2014-11-17 16:57:33.343298"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.344869"], ["updated_at", "2014-11-17 16:57:33.344869"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.346694"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.346694"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------- Commontator::CommentsController: test_0002_must get new if authorized ---------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.352802"], ["updated_at", "2014-11-17 16:57:33.352802"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.354160"], ["updated_at", "2014-11-17 16:57:33.354160"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.355699"], ["updated_at", "2014-11-17 16:57:33.355699"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.357245"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.357245"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 1ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0003_won't create unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.365436"], ["updated_at", "2014-11-17 16:57:33.365436"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.366646"], ["updated_at", "2014-11-17 16:57:33.366646"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.368042"], ["updated_at", "2014-11-17 16:57:33.368042"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.369613"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.369613"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.1ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-11-17 16:57:33.372330"], ["updated_at", "2014-11-17 16:57:33.372999"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0004_must create if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.376302"], ["updated_at", "2014-11-17 16:57:33.376302"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.377481"], ["updated_at", "2014-11-17 16:57:33.377481"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.378870"], ["updated_at", "2014-11-17 16:57:33.378870"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.380408"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.380408"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:57:33.383439"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.383439"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Another thing"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Another thing' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Another thing"], ["created_at", "2014-11-17 16:57:33.388311"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.388311"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"And this too"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'And this too' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "And this too"], ["created_at", "2014-11-17 16:57:33.392252"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.392252"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0005_won't create if double posting -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.395389"], ["updated_at", "2014-11-17 16:57:33.395389"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.397598"], ["updated_at", "2014-11-17 16:57:33.397598"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.399963"], ["updated_at", "2014-11-17 16:57:33.399963"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.402333"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.402333"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.2ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:57:33.414377"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.414377"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.5ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------- Commontator::CommentsController: test_0006_won't edit unless authorized -----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.421963"], ["updated_at", "2014-11-17 16:57:33.421963"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.423804"], ["updated_at", "2014-11-17 16:57:33.423804"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.426194"], ["updated_at", "2014-11-17 16:57:33.426194"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.428535"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.428535"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.2ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 4ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.435399"], ["updated_at", "2014-11-17 16:57:33.435399"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:57:33.439247"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.439247"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------ Commontator::CommentsController: test_0007_must edit if authorized ------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.443670"], ["updated_at", "2014-11-17 16:57:33.443670"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.444903"], ["updated_at", "2014-11-17 16:57:33.444903"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.446384"], ["updated_at", "2014-11-17 16:57:33.446384"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.447985"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.447985"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0008_won't update unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.459407"], ["updated_at", "2014-11-17 16:57:33.459407"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.460616"], ["updated_at", "2014-11-17 16:57:33.460616"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.462208"], ["updated_at", "2014-11-17 16:57:33.462208"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.463753"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.463753"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.468794"], ["updated_at", "2014-11-17 16:57:33.468794"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:57:33.472629"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.472629"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0009_must update if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.477214"], ["updated_at", "2014-11-17 16:57:33.477214"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.478611"], ["updated_at", "2014-11-17 16:57:33.478611"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.480941"], ["updated_at", "2014-11-17 16:57:33.480941"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.482549"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.482549"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["body", "Something else"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 16:57:33.487225"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.3ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------------------------------- Commontator::CommentsController: test_0010_won't delete unless authorized and not deleted -----------------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.498979"], ["updated_at", "2014-11-17 16:57:33.498979"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.501290"], ["updated_at", "2014-11-17 16:57:33.501290"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.503741"], ["updated_at", "2014-11-17 16:57:33.503741"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.506098"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.506098"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-11-17 16:57:33.516588') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-11-17 16:57:33.516588"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 16:57:33.518104"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:57:33.523370"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.523370"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["updated_at", "2014-11-17 16:57:33.524763"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.5ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------------------ Commontator::CommentsController: test_0011_must delete if authorized and not deleted ------------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.529871"], ["updated_at", "2014-11-17 16:57:33.529871"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.532034"], ["updated_at", "2014-11-17 16:57:33.532034"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.534248"], ["updated_at", "2014-11-17 16:57:33.534248"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.536341"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.536341"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-11-17 16:57:33.540797') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-11-17 16:57:33.540797"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 16:57:33.541866"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.543617"], ["updated_at", "2014-11-17 16:57:33.543617"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:57:33.545019"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.545019"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.3ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["updated_at", "2014-11-17 16:57:33.546979"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-11-17 16:57:33.549290') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-11-17 16:57:33.549290"], ["editor_id", 3], ["updated_at", "2014-11-17 16:57:33.550289"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["editor_id", 2], ["updated_at", "2014-11-17 16:57:33.552500"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-11-17 16:57:33.554620') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-11-17 16:57:33.554620"], ["editor_id", 3], ["updated_at", "2014-11-17 16:57:33.555586"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------------- Commontator::CommentsController: test_0012_won't undelete unless authorized and deleted ---------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.558160"], ["updated_at", "2014-11-17 16:57:33.558160"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.559431"], ["updated_at", "2014-11-17 16:57:33.559431"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.560969"], ["updated_at", "2014-11-17 16:57:33.560969"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.562644"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.562644"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-11-17 16:57:33.563262') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-11-17 16:57:33.563262"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 16:57:33.564062"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["updated_at", "2014-11-17 16:57:33.570478"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.574488"], ["updated_at", "2014-11-17 16:57:33.574488"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-11-17 16:57:33.575004') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-11-17 16:57:33.575004"], ["editor_id", 3], ["updated_at", "2014-11-17 16:57:33.575857"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 3]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:57:33.579608"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.579608"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["editor_id", 2], ["updated_at", "2014-11-17 16:57:33.581386"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-11-17 16:57:33.581835') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-11-17 16:57:33.581835"], ["updated_at", "2014-11-17 16:57:33.582542"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------------------- Commontator::CommentsController: test_0013_must undelete if authorized and deleted ----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.587484"], ["updated_at", "2014-11-17 16:57:33.587484"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.588654"], ["updated_at", "2014-11-17 16:57:33.588654"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.590762"], ["updated_at", "2014-11-17 16:57:33.590762"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.592723"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.592723"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-11-17 16:57:33.593488') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-11-17 16:57:33.593488"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 16:57:33.594362"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["updated_at", "2014-11-17 16:57:33.600550"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.602341"], ["updated_at", "2014-11-17 16:57:33.602341"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:57:33.603795"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.603795"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-11-17 16:57:33.604462') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-11-17 16:57:33.604462"], ["updated_at", "2014-11-17 16:57:33.605273"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["editor_id", 3], ["updated_at", "2014-11-17 16:57:33.608329"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-11-17 16:57:33.609506') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-11-17 16:57:33.609506"], ["editor_id", 2], ["updated_at", "2014-11-17 16:57:33.610348"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["editor_id", 3], ["updated_at", "2014-11-17 16:57:33.613209"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0014_won't upvote unless authorized -------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.616341"], ["updated_at", "2014-11-17 16:57:33.616341"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.618544"], ["updated_at", "2014-11-17 16:57:33.618544"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.620812"], ["updated_at", "2014-11-17 16:57:33.620812"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.623086"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.623086"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.633125"], ["updated_at", "2014-11-17 16:57:33.633125"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0015_must upvote if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.638680"], ["updated_at", "2014-11-17 16:57:33.638680"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.640036"], ["updated_at", "2014-11-17 16:57:33.640036"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.641615"], ["updated_at", "2014-11-17 16:57:33.641615"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.643167"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.643167"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.644077"], ["updated_at", "2014-11-17 16:57:33.644077"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:57:33.652495"], ["updated_at", "2014-11-17 16:57:33.652495"], ["votable_id", 1], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 3], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 10ms (ActiveRecord: 0.6ms)  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-11-17 16:57:33.666990"], ["vote_flag", "f"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-11-17 16:57:33.672739"], ["vote_flag", "t"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------- Commontator::CommentsController: test_0016_won't downvote unless authorized ---------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.678104"], ["updated_at", "2014-11-17 16:57:33.678104"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.679463"], ["updated_at", "2014-11-17 16:57:33.679463"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.681078"], ["updated_at", "2014-11-17 16:57:33.681078"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.682723"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.682723"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 7ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.695888"], ["updated_at", "2014-11-17 16:57:33.695888"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------------- Commontator::CommentsController: test_0017_must downvote if authorized ----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.701530"], ["updated_at", "2014-11-17 16:57:33.701530"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.702775"], ["updated_at", "2014-11-17 16:57:33.702775"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.704266"], ["updated_at", "2014-11-17 16:57:33.704266"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.705803"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.705803"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.706659"], ["updated_at", "2014-11-17 16:57:33.706659"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:57:33.710798"], ["updated_at", "2014-11-17 16:57:33.710798"], ["votable_id", 1], ["votable_type", "Commontator::Comment"], ["vote_flag", "f"], ["vote_weight", 1], ["voter_id", 3], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 7ms (ActiveRecord: 0.7ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-11-17 16:57:33.724441"], ["vote_flag", "t"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-11-17 16:57:33.729926"], ["vote_flag", "f"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.4ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0018_won't unvote unless authorized -------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.735672"], ["updated_at", "2014-11-17 16:57:33.735672"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.737995"], ["updated_at", "2014-11-17 16:57:33.737995"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.740390"], ["updated_at", "2014-11-17 16:57:33.740390"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.742700"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.742700"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:57:33.745398"], ["updated_at", "2014-11-17 16:57:33.745398"], ["votable_id", 1], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.754365"], ["updated_at", "2014-11-17 16:57:33.754365"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0019_must unvote if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.759768"], ["updated_at", "2014-11-17 16:57:33.759768"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.760954"], ["updated_at", "2014-11-17 16:57:33.760954"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.763164"], ["updated_at", "2014-11-17 16:57:33.763164"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.765593"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.765593"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.766886"], ["updated_at", "2014-11-17 16:57:33.766886"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:57:33.769405"], ["updated_at", "2014-11-17 16:57:33.769405"], ["votable_id", 1], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 3], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:57:33.786736"], ["updated_at", "2014-11-17 16:57:33.786736"], ["votable_id", 1], ["votable_type", "Commontator::Comment"], ["vote_flag", "f"], ["vote_weight", 1], ["voter_id", 3], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::CommentsController: test_0020_won't send mail if recipients empty ------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.797605"], ["updated_at", "2014-11-17 16:57:33.797605"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.798872"], ["updated_at", "2014-11-17 16:57:33.798872"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.800411"], ["updated_at", "2014-11-17 16:57:33.800411"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.802017"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.802017"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.802941"], ["updated_at", "2014-11-17 16:57:33.802941"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:57:33.806173"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.806173"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------- Commontator::CommentsController: test_0021_must send mail if recipients not empty ---------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.809322"], ["updated_at", "2014-11-17 16:57:33.809322"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.810566"], ["updated_at", "2014-11-17 16:57:33.810566"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.812036"], ["updated_at", "2014-11-17 16:57:33.812036"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.813542"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.813542"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.814421"], ["updated_at", "2014-11-17 16:57:33.814421"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 3], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 3) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:57:33.819187"], ["subscriber_id", 3], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.819187"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:57:33.822778"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:57:33.822778"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 3]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::ApplicationHelper: test_0001_must print javascript proc --------------------------------------------------------------------  (0.0ms) rollback transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.830481"], ["updated_at", "2014-11-17 16:57:33.830481"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.832229"], ["updated_at", "2014-11-17 16:57:33.832229"]]  (0.6ms) commit transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0001_won't subscribe unless authorized ---------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.835249"], ["updated_at", "2014-11-17 16:57:33.835249"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.836451"], ["updated_at", "2014-11-17 16:57:33.836451"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.837901"], ["updated_at", "2014-11-17 16:57:33.837901"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"2"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:57:33.843797"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-11-17 16:57:33.843797"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0002_must subscribe if authorized ----------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.848888"], ["updated_at", "2014-11-17 16:57:33.848888"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.850414"], ["updated_at", "2014-11-17 16:57:33.850414"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.852178"], ["updated_at", "2014-11-17 16:57:33.852178"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:57:33.856000"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-11-17 16:57:33.856000"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:57:33.861279"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-11-17 16:57:33.861279"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:57:33.871537"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-11-17 16:57:33.871537"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 9ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.5ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0003_won't unsubscribe unless authorized -----------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.875445"], ["updated_at", "2014-11-17 16:57:33.875445"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.877606"], ["updated_at", "2014-11-17 16:57:33.877606"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.880327"], ["updated_at", "2014-11-17 16:57:33.880327"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:57:33.883417"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-11-17 16:57:33.883417"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"2"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::SubscriptionsController: test_0004_must unsubscribe if authorized ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.892226"], ["updated_at", "2014-11-17 16:57:33.892226"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.893622"], ["updated_at", "2014-11-17 16:57:33.893622"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.895117"], ["updated_at", "2014-11-17 16:57:33.895117"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:57:33.897095"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-11-17 16:57:33.897095"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:57:33.902244"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-11-17 16:57:33.902244"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:57:33.906900"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-11-17 16:57:33.906900"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 3]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 2ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------- Commontator::Subscription: test_0001_must count unread comments ---------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.912154"], ["updated_at", "2014-11-17 16:57:33.912154"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.913468"], ["updated_at", "2014-11-17 16:57:33.913468"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.915678"], ["updated_at", "2014-11-17 16:57:33.915678"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:57:33.917251"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-11-17 16:57:33.917251"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 16:57:33.917251') [["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.920192"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-11-17 16:57:33.920192"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 16:57:33.917251') [["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:57:33.923593"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-11-17 16:57:33.923593"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 16:57:33.917251') [["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-11-17 16:57:33.926008' WHERE "commontator_subscriptions"."id" = 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 16:57:33.926008') [["thread_id", 2]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::SharedHelper: test_0001_must show commontator thread -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.931219"], ["updated_at", "2014-11-17 16:57:33.931219"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.932779"], ["updated_at", "2014-11-17 16:57:33.932779"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 2]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/shared/_thread.html.erb (7.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------ Commontator::SubscriptionsMailer: test_0001_must create deliverable mail ------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.950829"], ["updated_at", "2014-11-17 16:57:33.950829"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.952514"], ["updated_at", "2014-11-17 16:57:33.952514"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.954205"], ["updated_at", "2014-11-17 16:57:33.954205"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.955007"], ["updated_at", "2014-11-17 16:57:33.955007"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:57:33.957018"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-11-17 16:57:33.957018"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 2 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 3], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 3) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:57:33.958775"], ["subscriber_id", 3], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-11-17 16:57:33.958775"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:33.960421"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-11-17 16:57:33.960421"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 3]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/comments/_body.html.erb (2.1ms) Commontator::SubscriptionsMailer#comment_created: processed outbound mail in 13.4ms Sent mail to Undisclosed Recipients (4.5ms) Date: Mon, 17 Nov 2014 10:57:33 -0600 From: no-reply@dummy.com to: Undisclosed Recipients Message-ID: <546a28fdeee48_5abe3fd87c82dbf82293@Dantes-MacBook-Pro.local.mail> Subject: Dummy User #2 posted a comment on DummyModel #2 Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit

Dummy User #2 commented on DummyModel #2:

Something

Click here to view all comments on DummyModel #2.

 (0.4ms) rollback transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.985261"], ["updated_at", "2014-11-17 16:57:33.985261"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.987501"], ["updated_at", "2014-11-17 16:57:33.987501"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.989121"], ["updated_at", "2014-11-17 16:57:33.989121"]]  (0.6ms) commit transaction  (0.0ms) begin transaction DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] SQL (0.1ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 2 [["commontable_id", nil], ["updated_at", "2014-11-17 16:57:33.990918"]]  (0.7ms) commit transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.992895"], ["updated_at", "2014-11-17 16:57:33.992895"]]  (0.7ms) commit transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.995195"], ["updated_at", "2014-11-17 16:57:33.995195"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 3 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 3], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:33.997393"], ["updated_at", "2014-11-17 16:57:33.997393"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:33.999269"], ["updated_at", "2014-11-17 16:57:33.999269"]]  (0.5ms) commit transaction  (0.1ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:34.001221"], ["updated_at", "2014-11-17 16:57:34.001221"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 4]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 4 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 4], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:34.002796"], ["updated_at", "2014-11-17 16:57:34.002796"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 4 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 4], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 4 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 4) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:57:34.005863"], ["subscriber_id", 4], ["subscriber_type", "DummyUser"], ["thread_id", 4], ["updated_at", "2014-11-17 16:57:34.005863"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:34.007422"], ["updated_at", "2014-11-17 16:57:34.007422"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 4 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 5], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 4 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 5) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:57:34.010022"], ["subscriber_id", 5], ["subscriber_type", "DummyUser"], ["thread_id", 4], ["updated_at", "2014-11-17 16:57:34.010022"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 4]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 4]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:34.012896"], ["updated_at", "2014-11-17 16:57:34.012896"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:34.014648"], ["updated_at", "2014-11-17 16:57:34.014648"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 5 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 5], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:34.016080"], ["updated_at", "2014-11-17 16:57:34.016080"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 5 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 6], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 5 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 6) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:57:34.018739"], ["subscriber_id", 6], ["subscriber_type", "DummyUser"], ["thread_id", 5], ["updated_at", "2014-11-17 16:57:34.018739"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 5 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 6], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 5]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 5]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 16:57:34.018739') [["thread_id", 5]]  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 6 AND "commontator_comments"."thread_id" = 5 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:34.023390"], ["creator_id", 6], ["creator_type", "DummyUser"], ["thread_id", 5], ["updated_at", "2014-11-17 16:57:34.023390"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 5]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 16:57:34.018739') [["thread_id", 5]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 5 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 6], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction SQL (0.1ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-11-17 16:57:34.027165' WHERE "commontator_subscriptions"."id" = 3  (0.5ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 5]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 5]]  (0.2ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 16:57:34.027165') [["thread_id", 5]]  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:34.031795"], ["updated_at", "2014-11-17 16:57:34.031795"]]  (0.6ms) commit transaction  (0.1ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:34.033778"], ["updated_at", "2014-11-17 16:57:34.033778"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 6 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 6], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:34.035376"], ["updated_at", "2014-11-17 16:57:34.035376"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 7 AND "commontator_comments"."thread_id" = 6 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:34.037748"], ["creator_id", 7], ["creator_type", "DummyUser"], ["thread_id", 6], ["updated_at", "2014-11-17 16:57:34.037748"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 7 AND "commontator_comments"."thread_id" = 6 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:57:34.040006"], ["creator_id", 7], ["creator_type", "DummyUser"], ["thread_id", 6], ["updated_at", "2014-11-17 16:57:34.040006"]]  (0.6ms) commit transaction Commontator::Comment Load (0.2ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 6]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY created_at ASC [["thread_id", 6]]  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:34.042904"], ["updated_at", "2014-11-17 16:57:34.042904"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:34.044782"], ["updated_at", "2014-11-17 16:57:34.044782"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 7]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 7 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 7], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:34.046283"], ["updated_at", "2014-11-17 16:57:34.046283"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 8 AND "commontator_comments"."thread_id" = 7 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.3ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:57:34.054175"], ["creator_id", 8], ["creator_type", "DummyUser"], ["thread_id", 7], ["updated_at", "2014-11-17 16:57:34.054175"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 7 AND "commontator_threads"."id" != 7 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 7 [["closed_at", "2014-11-17 16:57:34.056023"], ["closer_id", 8], ["closer_type", "DummyUser"], ["updated_at", "2014-11-17 16:57:34.056973"]]  (0.6ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 4 LIMIT 1 [["thread_id", 7]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 7]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 7], ["commontable_type", "DummyModel"]]  (0.0ms) begin transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 7]] SQL (0.1ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "commontable_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 7 [["commontable_id", nil], ["commontable_type", nil], ["updated_at", "2014-11-17 16:57:34.061465"]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 7 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 7], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:34.062513"], ["updated_at", "2014-11-17 16:57:34.062513"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 7]]  (0.7ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 4 LIMIT 1 [["thread_id", 7]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 7]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 7], ["commontable_type", "DummyModel"]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 4 LIMIT 1 [["thread_id", 8]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:34.066508"], ["updated_at", "2014-11-17 16:57:34.066508"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:34.068561"], ["updated_at", "2014-11-17 16:57:34.068561"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 8]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 8 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 8], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:34.070058"], ["updated_at", "2014-11-17 16:57:34.070058"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 9 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 9], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 9 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 9) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:57:34.072877"], ["subscriber_id", 9], ["subscriber_type", "DummyUser"], ["thread_id", 9], ["updated_at", "2014-11-17 16:57:34.072877"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:34.074347"], ["updated_at", "2014-11-17 16:57:34.074347"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 9 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 10], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 9 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 10) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:57:34.076888"], ["subscriber_id", 10], ["subscriber_type", "DummyUser"], ["thread_id", 9], ["updated_at", "2014-11-17 16:57:34.076888"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 9 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 9], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 9 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 10], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 10]]  (0.1ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:34.081985"], ["updated_at", "2014-11-17 16:57:34.081985"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:57:34.083958"], ["updated_at", "2014-11-17 16:57:34.083958"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:57:34.085527"], ["updated_at", "2014-11-17 16:57:34.085527"]]  (0.6ms) commit transaction  (0.1ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.2ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-11-17 16:57:34.086924"], ["closer_id", 11], ["closer_type", "DummyUser"], ["updated_at", "2014-11-17 16:57:34.088047"]]  (0.6ms) commit transaction  (0.1ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.2ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", nil], ["updated_at", "2014-11-17 16:57:34.090637"]]  (0.7ms) commit transaction  (1.7ms) CREATE TABLE "commontator_comments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "creator_type" varchar(255), "creator_id" integer, "editor_type" varchar(255), "editor_id" integer, "thread_id" integer NOT NULL, "body" text NOT NULL, "deleted_at" datetime, "cached_votes_up" integer DEFAULT 0, "cached_votes_down" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime)   (0.1ms) select sqlite_version(*)  (0.9ms) CREATE INDEX "index_commontator_comments_on_cached_votes_down" ON "commontator_comments" ("cached_votes_down")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'  (0.8ms) CREATE INDEX "index_commontator_comments_on_cached_votes_up" ON "commontator_comments" ("cached_votes_up")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_comments_on_c_id_and_c_type_and_t_id" ON "commontator_comments" ("creator_id", "creator_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_comments_on_thread_id_and_created_at" ON "commontator_comments" ("thread_id", "created_at")  (0.7ms) CREATE TABLE "commontator_subscriptions" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "subscriber_type" varchar(255) NOT NULL, "subscriber_id" integer NOT NULL, "thread_id" integer NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE UNIQUE INDEX "index_commontator_subscriptions_on_s_id_and_s_type_and_t_id" ON "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_subscriptions_on_thread_id" ON "commontator_subscriptions" ("thread_id")  (0.7ms) CREATE TABLE "commontator_threads" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "commontable_type" varchar(255), "commontable_id" integer, "closed_at" datetime, "closer_type" varchar(255), "closer_id" integer, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE UNIQUE INDEX "index_commontator_threads_on_c_id_and_c_type" ON "commontator_threads" ("commontable_id", "commontable_type")  (0.7ms) CREATE TABLE "dummy_models" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.7ms) CREATE TABLE "dummy_users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)  (0.8ms) CREATE TABLE "votes" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "votable_id" integer, "votable_type" varchar(255), "voter_id" integer, "voter_type" varchar(255), "vote_flag" boolean, "vote_scope" varchar(255), "vote_weight" integer, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE INDEX "index_votes_on_votable_id_and_votable_type_and_vote_scope" ON "votes" ("votable_id", "votable_type", "vote_scope")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index'   (0.9ms) CREATE INDEX "index_votes_on_voter_id_and_voter_type_and_vote_scope" ON "votes" ("voter_id", "voter_type", "vote_scope")  (0.7ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)   (0.7ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.1ms) SELECT version FROM "schema_migrations"  (0.6ms) INSERT INTO "schema_migrations" (version) VALUES ('3')  (0.6ms) INSERT INTO "schema_migrations" (version) VALUES ('1')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('2')  (0.8ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.1ms) begin transaction ------------------------------------------------------------------------ Commontator::SubscriptionsMailer: test_0001_must create deliverable mail ------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.507342"], ["updated_at", "2014-11-17 16:58:38.507342"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.523314"], ["updated_at", "2014-11-17 16:58:38.523314"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.530778"], ["updated_at", "2014-11-17 16:58:38.530778"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.531844"], ["updated_at", "2014-11-17 16:58:38.531844"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:58:38.542357"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:58:38.542357"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:58:38.544458"], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:58:38.544458"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:38.551424"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:58:38.551424"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/comments/_body.html.erb (2.1ms) Rendered /Users/dante/Desktop/commontator/app/views/commontator/subscriptions_mailer/comment_created.html.erb (5.0ms) Commontator::SubscriptionsMailer#comment_created: processed outbound mail in 17.9ms Sent mail to Undisclosed Recipients (4.1ms) Date: Mon, 17 Nov 2014 10:58:38 -0600 From: no-reply@dummy.com to: Undisclosed Recipients Message-ID: <546a293e8c4cf_5ac63fc39202dbdc294eb@Dantes-MacBook-Pro.local.mail> Subject: Dummy User #1 posted a comment on DummyModel #1 Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit

Dummy User #1 commented on DummyModel #1:

Something

Click here to view all comments on DummyModel #1.

 (1.2ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------- Commontator::Subscription: test_0001_must count unread comments ---------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.582890"], ["updated_at", "2014-11-17 16:58:38.582890"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.585467"], ["updated_at", "2014-11-17 16:58:38.585467"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.588007"], ["updated_at", "2014-11-17 16:58:38.588007"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:58:38.590057"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:58:38.590057"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 16:58:38.590057') [["thread_id", 1]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:38.594151"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:58:38.594151"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 16:58:38.590057') [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:58:38.597737"], ["creator_id", 1], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:58:38.597737"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 16:58:38.590057') [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-11-17 16:58:38.600386' WHERE "commontator_subscriptions"."id" = 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 16:58:38.600386') [["thread_id", 1]]  (0.4ms) rollback transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.604499"], ["updated_at", "2014-11-17 16:58:38.604499"]]  (0.6ms) commit transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::SharedHelper: test_0001_must show commontator thread -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.610564"], ["updated_at", "2014-11-17 16:58:38.610564"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.612269"], ["updated_at", "2014-11-17 16:58:38.612269"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Rendered /Users/dante/Desktop/commontator/app/views/commontator/shared/_thread.html.erb (7.7ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------- Commontator::ThreadsController: test_0001_won't show unless authorized ----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.628447"], ["updated_at", "2014-11-17 16:58:38.628447"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.629859"], ["updated_at", "2014-11-17 16:58:38.629859"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.631429"], ["updated_at", "2014-11-17 16:58:38.631429"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------- Commontator::ThreadsController: test_0002_must show if authorized -----------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.638491"], ["updated_at", "2014-11-17 16:58:38.638491"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.640770"], ["updated_at", "2014-11-17 16:58:38.640770"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.643141"], ["updated_at", "2014-11-17 16:58:38.643141"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 1], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/1 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 1], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 1], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------------------- Commontator::ThreadsController: test_0003_won't close unless authorized and open --------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.655931"], ["updated_at", "2014-11-17 16:58:38.655931"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.657180"], ["updated_at", "2014-11-17 16:58:38.657180"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.658646"], ["updated_at", "2014-11-17 16:58:38.658646"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-11-17 16:58:38.663861"], ["updated_at", "2014-11-17 16:58:38.665042"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------- Commontator::ThreadsController: test_0004_must close if authorized and open ---------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.670887"], ["updated_at", "2014-11-17 16:58:38.670887"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.672103"], ["updated_at", "2014-11-17 16:58:38.672103"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.673514"], ["updated_at", "2014-11-17 16:58:38.673514"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-11-17 16:58:38.675448"], ["closer_id", 2], ["closer_type", "DummyUser"], ["updated_at", "2014-11-17 16:58:38.676153"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-11-17 16:58:38.678157"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-11-17 16:58:38.679596"], ["updated_at", "2014-11-17 16:58:38.680340"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.3ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------------------------- Commontator::ThreadsController: test_0005_won't reopen unless authorized and closed -----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.682692"], ["updated_at", "2014-11-17 16:58:38.682692"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.683888"], ["updated_at", "2014-11-17 16:58:38.683888"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.685392"], ["updated_at", "2014-11-17 16:58:38.685392"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-11-17 16:58:38.686002"], ["updated_at", "2014-11-17 16:58:38.686603"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-11-17 16:58:38.692272"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------------ Commontator::ThreadsController: test_0006_must reopen if authorized and closed ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.695839"], ["updated_at", "2014-11-17 16:58:38.695839"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.697021"], ["updated_at", "2014-11-17 16:58:38.697021"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.698428"], ["updated_at", "2014-11-17 16:58:38.698428"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-11-17 16:58:38.699000"], ["updated_at", "2014-11-17 16:58:38.699563"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-11-17 16:58:38.702367"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-11-17 16:58:38.703738"], ["updated_at", "2014-11-17 16:58:38.704352"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-11-17 16:58:38.707429"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------------- Commontator::Comment: test_0001_must be votable if acts_as_votable is installed -------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.712847"], ["updated_at", "2014-11-17 16:58:38.712847"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.714826"], ["updated_at", "2014-11-17 16:58:38.714826"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.717095"], ["updated_at", "2014-11-17 16:58:38.717095"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.5ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------- Commontator::Comment: test_0002_must know if it has been modified -----------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.722761"], ["updated_at", "2014-11-17 16:58:38.722761"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.725007"], ["updated_at", "2014-11-17 16:58:38.725007"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.727324"], ["updated_at", "2014-11-17 16:58:38.727324"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:38.729921"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:58:38.729921"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["body", "Something else"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 16:58:38.731919"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------- Commontator::Comment: test_0003_must know if it has been deleted ----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.733773"], ["updated_at", "2014-11-17 16:58:38.733773"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.735193"], ["updated_at", "2014-11-17 16:58:38.735193"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.736717"], ["updated_at", "2014-11-17 16:58:38.736717"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-11-17 16:58:38.737580') LIMIT 1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.738549"], ["updated_at", "2014-11-17 16:58:38.738549"]] SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "deleted_at", "editor_id", "editor_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:38.739043"], ["creator_id", 2], ["creator_type", "DummyUser"], ["deleted_at", "2014-11-17 16:58:38.737580"], ["editor_id", 3], ["editor_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:58:38.739043"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["updated_at", "2014-11-17 16:58:38.740597"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.3ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------- Commontator::Comment: test_0004_must make proper timestamps -----------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.742007"], ["updated_at", "2014-11-17 16:58:38.742007"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.743138"], ["updated_at", "2014-11-17 16:58:38.743138"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.744722"], ["updated_at", "2014-11-17 16:58:38.744722"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:38.746310"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 16:58:38.746310"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.747906"], ["updated_at", "2014-11-17 16:58:38.747906"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["body", "Something else"], ["editor_id", 3], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 16:58:38.749806"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.1ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.752837"], ["updated_at", "2014-11-17 16:58:38.752837"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.754352"], ["updated_at", "2014-11-17 16:58:38.754352"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.756305"], ["updated_at", "2014-11-17 16:58:38.756305"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.758022"], ["updated_at", "2014-11-17 16:58:38.758022"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.759416"], ["updated_at", "2014-11-17 16:58:38.759416"]]  (0.7ms) commit transaction  (0.1ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.761040"], ["updated_at", "2014-11-17 16:58:38.761040"]]  (0.5ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.762658"], ["updated_at", "2014-11-17 16:58:38.762658"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 3 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 3], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.764011"], ["updated_at", "2014-11-17 16:58:38.764011"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 3 AND "commontator_threads"."id" != 3 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 3 [["closed_at", "2014-11-17 16:58:38.765294"], ["closer_id", 3], ["closer_type", "DummyUser"], ["updated_at", "2014-11-17 16:58:38.765969"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 3 AND "commontator_threads"."id" != 3 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 3 [["closed_at", nil], ["updated_at", "2014-11-17 16:58:38.767818"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.769228"], ["updated_at", "2014-11-17 16:58:38.769228"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.771023"], ["updated_at", "2014-11-17 16:58:38.771023"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 4]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 4 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 4], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.772443"], ["updated_at", "2014-11-17 16:58:38.772443"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 4 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 4], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 4 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 4) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:58:38.775206"], ["subscriber_id", 4], ["subscriber_type", "DummyUser"], ["thread_id", 4], ["updated_at", "2014-11-17 16:58:38.775206"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.776693"], ["updated_at", "2014-11-17 16:58:38.776693"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 4 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 5], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 4 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 5) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:58:38.779251"], ["subscriber_id", 5], ["subscriber_type", "DummyUser"], ["thread_id", 4], ["updated_at", "2014-11-17 16:58:38.779251"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 4]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 4]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.782152"], ["updated_at", "2014-11-17 16:58:38.782152"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.783882"], ["updated_at", "2014-11-17 16:58:38.783882"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 5 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 5], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.785355"], ["updated_at", "2014-11-17 16:58:38.785355"]]  (0.5ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 6 AND "commontator_comments"."thread_id" = 5 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:38.787632"], ["creator_id", 6], ["creator_type", "DummyUser"], ["thread_id", 5], ["updated_at", "2014-11-17 16:58:38.787632"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 5 AND "commontator_threads"."id" != 5 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 5 [["closed_at", "2014-11-17 16:58:38.788902"], ["closer_id", 6], ["closer_type", "DummyUser"], ["updated_at", "2014-11-17 16:58:38.789668"]]  (0.6ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 1 LIMIT 1 [["thread_id", 5]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 5], ["commontable_type", "DummyModel"]]  (0.1ms) begin transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 5]] SQL (0.2ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "commontable_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 5 [["commontable_id", nil], ["commontable_type", nil], ["updated_at", "2014-11-17 16:58:38.795538"]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 5 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 5], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.797025"], ["updated_at", "2014-11-17 16:58:38.797025"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 5]]  (0.8ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 1 LIMIT 1 [["thread_id", 5]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 5], ["commontable_type", "DummyModel"]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 1 LIMIT 1 [["thread_id", 6]]  (0.1ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.802053"], ["updated_at", "2014-11-17 16:58:38.802053"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.804038"], ["updated_at", "2014-11-17 16:58:38.804038"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 6 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 6], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.805718"], ["updated_at", "2014-11-17 16:58:38.805718"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 7 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 7], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 7 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 7) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:58:38.808537"], ["subscriber_id", 7], ["subscriber_type", "DummyUser"], ["thread_id", 7], ["updated_at", "2014-11-17 16:58:38.808537"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 7 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 7], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 7]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 6]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 16:58:38.808537') [["thread_id", 7]]  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 7 AND "commontator_comments"."thread_id" = 7 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:38.812862"], ["creator_id", 7], ["creator_type", "DummyUser"], ["thread_id", 7], ["updated_at", "2014-11-17 16:58:38.812862"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 7]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 6]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 16:58:38.808537') [["thread_id", 7]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 7 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 7], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction SQL (0.1ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-11-17 16:58:38.816578' WHERE "commontator_subscriptions"."id" = 3  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 7]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 6]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 16:58:38.816578') [["thread_id", 7]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.819858"], ["updated_at", "2014-11-17 16:58:38.819858"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.821546"], ["updated_at", "2014-11-17 16:58:38.821546"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 7]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 7 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 7], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.822980"], ["updated_at", "2014-11-17 16:58:38.822980"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 8 AND "commontator_comments"."thread_id" = 8 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:38.825170"], ["creator_id", 8], ["creator_type", "DummyUser"], ["thread_id", 8], ["updated_at", "2014-11-17 16:58:38.825170"]]  (5.6ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 8 AND "commontator_comments"."thread_id" = 8 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:58:38.832639"], ["creator_id", 8], ["creator_type", "DummyUser"], ["thread_id", 8], ["updated_at", "2014-11-17 16:58:38.832639"]]  (0.6ms) commit transaction Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 8]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY created_at ASC [["thread_id", 8]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.835429"], ["updated_at", "2014-11-17 16:58:38.835429"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.837371"], ["updated_at", "2014-11-17 16:58:38.837371"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 8]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 8 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 8], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.838865"], ["updated_at", "2014-11-17 16:58:38.838865"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 9 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 9], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 9 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 9) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:58:38.842100"], ["subscriber_id", 9], ["subscriber_type", "DummyUser"], ["thread_id", 9], ["updated_at", "2014-11-17 16:58:38.842100"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.843686"], ["updated_at", "2014-11-17 16:58:38.843686"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 9 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 10], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 9 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 10) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:58:38.846320"], ["subscriber_id", 10], ["subscriber_type", "DummyUser"], ["thread_id", 9], ["updated_at", "2014-11-17 16:58:38.846320"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 9 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 9], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 9 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 10], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.850425"], ["updated_at", "2014-11-17 16:58:38.850425"]]  (0.5ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.852159"], ["updated_at", "2014-11-17 16:58:38.852159"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.853663"], ["updated_at", "2014-11-17 16:58:38.853663"]]  (0.6ms) commit transaction  (0.0ms) begin transaction DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] SQL (0.1ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["commontable_id", nil], ["updated_at", "2014-11-17 16:58:38.855415"]]  (0.6ms) commit transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) begin transaction --------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0001_won't subscribe unless authorized ---------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.858591"], ["updated_at", "2014-11-17 16:58:38.858591"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.859759"], ["updated_at", "2014-11-17 16:58:38.859759"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.861104"], ["updated_at", "2014-11-17 16:58:38.861104"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"11"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 11 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:58:38.866900"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:38.866900"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0002_must subscribe if authorized ----------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.871177"], ["updated_at", "2014-11-17 16:58:38.871177"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.872379"], ["updated_at", "2014-11-17 16:58:38.872379"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.873838"], ["updated_at", "2014-11-17 16:58:38.873838"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 11 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:58:38.877328"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:38.877328"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 6]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 11 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:58:38.882302"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:38.882302"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 7]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 11 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:58:38.887014"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:38.887014"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0003_won't unsubscribe unless authorized -----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.889910"], ["updated_at", "2014-11-17 16:58:38.889910"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.891532"], ["updated_at", "2014-11-17 16:58:38.891532"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.893311"], ["updated_at", "2014-11-17 16:58:38.893311"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 11 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:58:38.895300"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:38.895300"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"11"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 6]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::SubscriptionsController: test_0004_must unsubscribe if authorized ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.903424"], ["updated_at", "2014-11-17 16:58:38.903424"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.904651"], ["updated_at", "2014-11-17 16:58:38.904651"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.906135"], ["updated_at", "2014-11-17 16:58:38.906135"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 11 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:58:38.908070"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:38.908070"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 6]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 11 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:58:38.914131"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:38.914131"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 7]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 11 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:58:38.918978"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:38.918978"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 8]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.4ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------------- Commontator::CommentsController: test_0001_won't get new unless authorized --------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.925259"], ["updated_at", "2014-11-17 16:58:38.925259"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.927317"], ["updated_at", "2014-11-17 16:58:38.927317"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.929666"], ["updated_at", "2014-11-17 16:58:38.929666"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:38.931907"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:38.931907"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"11"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------- Commontator::CommentsController: test_0002_must get new if authorized ---------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.938381"], ["updated_at", "2014-11-17 16:58:38.938381"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.939930"], ["updated_at", "2014-11-17 16:58:38.939930"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.941558"], ["updated_at", "2014-11-17 16:58:38.941558"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:38.943163"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:38.943163"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 1ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 1ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0003_won't create unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.951223"], ["updated_at", "2014-11-17 16:58:38.951223"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.952422"], ["updated_at", "2014-11-17 16:58:38.952422"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.953852"], ["updated_at", "2014-11-17 16:58:38.953852"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:38.955413"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:38.955413"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 11 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 11 [["closed_at", "2014-11-17 16:58:38.958186"], ["updated_at", "2014-11-17 16:58:38.958960"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0004_must create if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.962292"], ["updated_at", "2014-11-17 16:58:38.962292"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.963500"], ["updated_at", "2014-11-17 16:58:38.963500"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.965184"], ["updated_at", "2014-11-17 16:58:38.965184"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:38.967140"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:38.967140"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:58:38.970462"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:38.970462"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Another thing"}} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Another thing' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Another thing"], ["created_at", "2014-11-17 16:58:38.974621"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:38.974621"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"And this too"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'And this too' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "And this too"], ["created_at", "2014-11-17 16:58:38.978333"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:38.978333"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0005_won't create if double posting -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.981277"], ["updated_at", "2014-11-17 16:58:38.981277"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.982584"], ["updated_at", "2014-11-17 16:58:38.982584"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:38.984001"], ["updated_at", "2014-11-17 16:58:38.984001"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:38.985574"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:38.985574"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:58:38.992360"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:38.992360"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------- Commontator::CommentsController: test_0006_won't edit unless authorized -----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:38.999588"], ["updated_at", "2014-11-17 16:58:38.999588"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.001073"], ["updated_at", "2014-11-17 16:58:39.001073"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:39.002712"], ["updated_at", "2014-11-17 16:58:39.002712"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:39.004402"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.004402"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.2ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.009201"], ["updated_at", "2014-11-17 16:58:39.009201"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 7ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:58:39.018464"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.018464"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------ Commontator::CommentsController: test_0007_must edit if authorized ------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.023083"], ["updated_at", "2014-11-17 16:58:39.023083"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.024289"], ["updated_at", "2014-11-17 16:58:39.024289"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:39.025742"], ["updated_at", "2014-11-17 16:58:39.025742"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:39.027262"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.027262"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0008_won't update unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.038628"], ["updated_at", "2014-11-17 16:58:39.038628"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.039891"], ["updated_at", "2014-11-17 16:58:39.039891"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:39.042004"], ["updated_at", "2014-11-17 16:58:39.042004"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:39.043643"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.043643"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.048929"], ["updated_at", "2014-11-17 16:58:39.048929"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:58:39.052721"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.052721"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0009_must update if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.057377"], ["updated_at", "2014-11-17 16:58:39.057377"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.058569"], ["updated_at", "2014-11-17 16:58:39.058569"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:39.059997"], ["updated_at", "2014-11-17 16:58:39.059997"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:39.061538"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.061538"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["body", "Something else"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 16:58:39.065759"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 4ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 4ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 4ms (ActiveRecord: 0.3ms)  (0.3ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------------- Commontator::CommentsController: test_0010_won't delete unless authorized and not deleted -----------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.077502"], ["updated_at", "2014-11-17 16:58:39.077502"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.078760"], ["updated_at", "2014-11-17 16:58:39.078760"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:39.080250"], ["updated_at", "2014-11-17 16:58:39.080250"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:39.082380"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.082380"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-11-17 16:58:39.087390') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 16:58:39.087390"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 16:58:39.088690"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:58:39.093784"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.093784"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-11-17 16:58:39.095171"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------------ Commontator::CommentsController: test_0011_must delete if authorized and not deleted ------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.099683"], ["updated_at", "2014-11-17 16:58:39.099683"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.100875"], ["updated_at", "2014-11-17 16:58:39.100875"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:39.102326"], ["updated_at", "2014-11-17 16:58:39.102326"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:39.103862"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.103862"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-11-17 16:58:39.107188') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 16:58:39.107188"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 16:58:39.108106"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 4ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.109804"], ["updated_at", "2014-11-17 16:58:39.109804"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:58:39.111221"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.111221"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-11-17 16:58:39.112794"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.2ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-11-17 16:58:39.114852') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 16:58:39.114852"], ["editor_id", 13], ["updated_at", "2014-11-17 16:58:39.116396"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 4ms (ActiveRecord: 0.5ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 12], ["updated_at", "2014-11-17 16:58:39.118661"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-11-17 16:58:39.120814') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 16:58:39.120814"], ["editor_id", 13], ["updated_at", "2014-11-17 16:58:39.121707"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------------- Commontator::CommentsController: test_0012_won't undelete unless authorized and deleted ---------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.124203"], ["updated_at", "2014-11-17 16:58:39.124203"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.125493"], ["updated_at", "2014-11-17 16:58:39.125493"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:39.126932"], ["updated_at", "2014-11-17 16:58:39.126932"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:39.128481"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.128481"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-11-17 16:58:39.129126') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 16:58:39.129126"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 16:58:39.129981"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-11-17 16:58:39.136296"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.140146"], ["updated_at", "2014-11-17 16:58:39.140146"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-11-17 16:58:39.140717') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 16:58:39.140717"], ["editor_id", 13], ["updated_at", "2014-11-17 16:58:39.141625"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 13]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:58:39.145347"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.145347"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 12], ["updated_at", "2014-11-17 16:58:39.147159"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-11-17 16:58:39.147612') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 16:58:39.147612"], ["updated_at", "2014-11-17 16:58:39.148377"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------------------- Commontator::CommentsController: test_0013_must undelete if authorized and deleted ----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.153144"], ["updated_at", "2014-11-17 16:58:39.153144"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.154316"], ["updated_at", "2014-11-17 16:58:39.154316"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:39.155780"], ["updated_at", "2014-11-17 16:58:39.155780"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:39.157334"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.157334"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-11-17 16:58:39.157963') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 16:58:39.157963"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 16:58:39.158968"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-11-17 16:58:39.163678"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 4ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.165863"], ["updated_at", "2014-11-17 16:58:39.165863"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:58:39.167520"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.167520"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-11-17 16:58:39.168217') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 16:58:39.168217"], ["updated_at", "2014-11-17 16:58:39.169101"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 13], ["updated_at", "2014-11-17 16:58:39.172270"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-11-17 16:58:39.173588') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 16:58:39.173588"], ["editor_id", 12], ["updated_at", "2014-11-17 16:58:39.174432"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 13], ["updated_at", "2014-11-17 16:58:39.177284"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 6ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0014_won't upvote unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.183186"], ["updated_at", "2014-11-17 16:58:39.183186"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.184452"], ["updated_at", "2014-11-17 16:58:39.184452"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:39.185928"], ["updated_at", "2014-11-17 16:58:39.185928"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:39.187499"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.187499"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.196500"], ["updated_at", "2014-11-17 16:58:39.196500"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0015_must upvote if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.201911"], ["updated_at", "2014-11-17 16:58:39.201911"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.203141"], ["updated_at", "2014-11-17 16:58:39.203141"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:39.204654"], ["updated_at", "2014-11-17 16:58:39.204654"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:39.206203"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.206203"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.207067"], ["updated_at", "2014-11-17 16:58:39.207067"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:58:39.215064"], ["updated_at", "2014-11-17 16:58:39.215064"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 10ms (ActiveRecord: 0.7ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 6ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-11-17 16:58:39.228974"], ["vote_flag", "f"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-11-17 16:58:39.234695"], ["vote_flag", "t"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------- Commontator::CommentsController: test_0016_won't downvote unless authorized ---------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.240007"], ["updated_at", "2014-11-17 16:58:39.240007"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.241289"], ["updated_at", "2014-11-17 16:58:39.241289"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:39.242810"], ["updated_at", "2014-11-17 16:58:39.242810"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:39.244389"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.244389"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.251456"], ["updated_at", "2014-11-17 16:58:39.251456"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------- Commontator::CommentsController: test_0017_must downvote if authorized ----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.256701"], ["updated_at", "2014-11-17 16:58:39.256701"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.257885"], ["updated_at", "2014-11-17 16:58:39.257885"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:39.259312"], ["updated_at", "2014-11-17 16:58:39.259312"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:39.260863"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.260863"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.261804"], ["updated_at", "2014-11-17 16:58:39.261804"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:58:39.265807"], ["updated_at", "2014-11-17 16:58:39.265807"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "f"], ["vote_weight", 1], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 5ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-11-17 16:58:39.278455"], ["vote_flag", "t"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-11-17 16:58:39.284719"], ["vote_flag", "f"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 7ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0018_won't unvote unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.290203"], ["updated_at", "2014-11-17 16:58:39.290203"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.291586"], ["updated_at", "2014-11-17 16:58:39.291586"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:39.293138"], ["updated_at", "2014-11-17 16:58:39.293138"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:39.294733"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.294733"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:58:39.296749"], ["updated_at", "2014-11-17 16:58:39.296749"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 12], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.305518"], ["updated_at", "2014-11-17 16:58:39.305518"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0019_must unvote if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.310867"], ["updated_at", "2014-11-17 16:58:39.310867"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.312055"], ["updated_at", "2014-11-17 16:58:39.312055"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:39.313517"], ["updated_at", "2014-11-17 16:58:39.313517"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:39.315129"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.315129"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.315994"], ["updated_at", "2014-11-17 16:58:39.315994"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:58:39.317827"], ["updated_at", "2014-11-17 16:58:39.317827"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 6ms (ActiveRecord: 0.7ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:58:39.334711"], ["updated_at", "2014-11-17 16:58:39.334711"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "f"], ["vote_weight", 1], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 13 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 6ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::CommentsController: test_0020_won't send mail if recipients empty ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.351987"], ["updated_at", "2014-11-17 16:58:39.351987"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.353285"], ["updated_at", "2014-11-17 16:58:39.353285"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:39.354818"], ["updated_at", "2014-11-17 16:58:39.354818"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:39.356416"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.356416"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.357358"], ["updated_at", "2014-11-17 16:58:39.357358"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:58:39.360618"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.360618"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------- Commontator::CommentsController: test_0021_must send mail if recipients not empty ---------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.363670"], ["updated_at", "2014-11-17 16:58:39.363670"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.364837"], ["updated_at", "2014-11-17 16:58:39.364837"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 16:58:39.366313"], ["updated_at", "2014-11-17 16:58:39.366313"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 16:58:39.367829"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.367829"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 16:58:39.368699"], ["updated_at", "2014-11-17 16:58:39.368699"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 13], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 11 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 13) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 16:58:39.370577"], ["subscriber_id", 13], ["subscriber_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.370577"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 16:58:39.373732"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 16:58:39.373732"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 11]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 13]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 4ms (ActiveRecord: 0.4ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::ApplicationHelper: test_0001_must print javascript proc --------------------------------------------------------------------  (0.0ms) rollback transaction  (1.6ms) CREATE TABLE "commontator_comments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "creator_type" varchar(255), "creator_id" integer, "editor_type" varchar(255), "editor_id" integer, "thread_id" integer NOT NULL, "body" text NOT NULL, "deleted_at" datetime, "cached_votes_up" integer DEFAULT 0, "cached_votes_down" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime)   (0.1ms) select sqlite_version(*)  (0.7ms) CREATE INDEX "index_commontator_comments_on_cached_votes_down" ON "commontator_comments" ("cached_votes_down")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'  (0.7ms) CREATE INDEX "index_commontator_comments_on_cached_votes_up" ON "commontator_comments" ("cached_votes_up")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.7ms) CREATE INDEX "index_commontator_comments_on_c_id_and_c_type_and_t_id" ON "commontator_comments" ("creator_id", "creator_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_comments_on_thread_id_and_created_at" ON "commontator_comments" ("thread_id", "created_at")  (0.7ms) CREATE TABLE "commontator_subscriptions" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "subscriber_type" varchar(255) NOT NULL, "subscriber_id" integer NOT NULL, "thread_id" integer NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE UNIQUE INDEX "index_commontator_subscriptions_on_s_id_and_s_type_and_t_id" ON "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index'   (0.7ms) CREATE INDEX "index_commontator_subscriptions_on_thread_id" ON "commontator_subscriptions" ("thread_id")  (0.7ms) CREATE TABLE "commontator_threads" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "commontable_type" varchar(255), "commontable_id" integer, "closed_at" datetime, "closer_type" varchar(255), "closer_id" integer, "created_at" datetime, "updated_at" datetime)   (0.7ms) CREATE UNIQUE INDEX "index_commontator_threads_on_c_id_and_c_type" ON "commontator_threads" ("commontable_id", "commontable_type")  (0.8ms) CREATE TABLE "dummy_models" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.7ms) CREATE TABLE "dummy_users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)  (0.7ms) CREATE TABLE "votes" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "votable_id" integer, "votable_type" varchar(255), "voter_id" integer, "voter_type" varchar(255), "vote_flag" boolean, "vote_scope" varchar(255), "vote_weight" integer, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE INDEX "index_votes_on_votable_id_and_votable_type_and_vote_scope" ON "votes" ("votable_id", "votable_type", "vote_scope")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index'   (0.8ms) CREATE INDEX "index_votes_on_voter_id_and_voter_type_and_vote_scope" ON "votes" ("voter_id", "voter_type", "vote_scope")  (0.8ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)   (0.7ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.1ms) SELECT version FROM "schema_migrations"  (0.6ms) INSERT INTO "schema_migrations" (version) VALUES ('3')  (0.6ms) INSERT INTO "schema_migrations" (version) VALUES ('1')  (0.6ms) INSERT INTO "schema_migrations" (version) VALUES ('2')  (0.6ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.1ms) begin transaction --------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0001_won't subscribe unless authorized ---------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.526239"], ["updated_at", "2014-11-17 17:04:12.526239"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.542782"], ["updated_at", "2014-11-17 17:04:12.542782"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.550493"], ["updated_at", "2014-11-17 17:04:12.550493"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:04:12.565876"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.565876"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0002_must subscribe if authorized ----------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.571743"], ["updated_at", "2014-11-17 17:04:12.571743"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.573306"], ["updated_at", "2014-11-17 17:04:12.573306"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.575221"], ["updated_at", "2014-11-17 17:04:12.575221"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:04:12.579364"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.579364"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:04:12.584712"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.584712"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:04:12.589790"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.589790"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0003_won't unsubscribe unless authorized -----------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.592736"], ["updated_at", "2014-11-17 17:04:12.592736"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.594030"], ["updated_at", "2014-11-17 17:04:12.594030"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.595615"], ["updated_at", "2014-11-17 17:04:12.595615"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:04:12.597765"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.597765"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::SubscriptionsController: test_0004_must unsubscribe if authorized ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.606000"], ["updated_at", "2014-11-17 17:04:12.606000"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.607295"], ["updated_at", "2014-11-17 17:04:12.607295"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.608849"], ["updated_at", "2014-11-17 17:04:12.608849"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:04:12.610978"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.610978"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:04:12.617082"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.617082"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:04:12.621929"], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.621929"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 3]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::ApplicationHelper: test_0001_must print javascript proc --------------------------------------------------------------------  (0.0ms) rollback transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.629580"], ["updated_at", "2014-11-17 17:04:12.629580"]]  (0.7ms) commit transaction  (0.0ms) begin transaction ---------------------------------------------------------------------- Commontator::ThreadsController: test_0001_won't show unless authorized ----------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.633032"], ["updated_at", "2014-11-17 17:04:12.633032"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.634614"], ["updated_at", "2014-11-17 17:04:12.634614"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.636614"], ["updated_at", "2014-11-17 17:04:12.636614"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.3ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::ThreadsController: test_0002_must show if authorized -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.642654"], ["updated_at", "2014-11-17 17:04:12.642654"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.644018"], ["updated_at", "2014-11-17 17:04:12.644018"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.645618"], ["updated_at", "2014-11-17 17:04:12.645618"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 1], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/1 Completed 302 Found in 4ms (ActiveRecord: 0.2ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 1], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 1], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.3ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------------------- Commontator::ThreadsController: test_0003_won't close unless authorized and open --------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.657435"], ["updated_at", "2014-11-17 17:04:12.657435"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.658737"], ["updated_at", "2014-11-17 17:04:12.658737"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.660270"], ["updated_at", "2014-11-17 17:04:12.660270"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 5ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-11-17 17:04:12.669988"], ["updated_at", "2014-11-17 17:04:12.671040"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------- Commontator::ThreadsController: test_0004_must close if authorized and open ---------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.675762"], ["updated_at", "2014-11-17 17:04:12.675762"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.677558"], ["updated_at", "2014-11-17 17:04:12.677558"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.679649"], ["updated_at", "2014-11-17 17:04:12.679649"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-11-17 17:04:12.682224"], ["closer_id", 2], ["closer_type", "DummyUser"], ["updated_at", "2014-11-17 17:04:12.683108"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-11-17 17:04:12.685395"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-11-17 17:04:12.687126"], ["updated_at", "2014-11-17 17:04:12.687841"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.3ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------- Commontator::ThreadsController: test_0005_won't reopen unless authorized and closed -----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.690251"], ["updated_at", "2014-11-17 17:04:12.690251"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.691533"], ["updated_at", "2014-11-17 17:04:12.691533"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.693028"], ["updated_at", "2014-11-17 17:04:12.693028"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-11-17 17:04:12.693708"], ["updated_at", "2014-11-17 17:04:12.694345"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-11-17 17:04:12.700328"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.3ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::ThreadsController: test_0006_must reopen if authorized and closed ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.703870"], ["updated_at", "2014-11-17 17:04:12.703870"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.705095"], ["updated_at", "2014-11-17 17:04:12.705095"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.706505"], ["updated_at", "2014-11-17 17:04:12.706505"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-11-17 17:04:12.707078"], ["updated_at", "2014-11-17 17:04:12.707647"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-11-17 17:04:12.710443"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-11-17 17:04:12.711833"], ["updated_at", "2014-11-17 17:04:12.712456"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-11-17 17:04:12.714857"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.3ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::SharedHelper: test_0001_must show commontator thread -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.722595"], ["updated_at", "2014-11-17 17:04:12.722595"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.724111"], ["updated_at", "2014-11-17 17:04:12.724111"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 1]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/shared/_thread.html.erb (12.3ms)  (0.6ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------------- Commontator::CommentsController: test_0001_won't get new unless authorized --------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.745771"], ["updated_at", "2014-11-17 17:04:12.745771"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.747703"], ["updated_at", "2014-11-17 17:04:12.747703"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.750069"], ["updated_at", "2014-11-17 17:04:12.750069"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:12.757401"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.757401"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------- Commontator::CommentsController: test_0002_must get new if authorized ---------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.765606"], ["updated_at", "2014-11-17 17:04:12.765606"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.767465"], ["updated_at", "2014-11-17 17:04:12.767465"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.769212"], ["updated_at", "2014-11-17 17:04:12.769212"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:12.770926"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.770926"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 1ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 1ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.3ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0003_won't create unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.779148"], ["updated_at", "2014-11-17 17:04:12.779148"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.780545"], ["updated_at", "2014-11-17 17:04:12.780545"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.782044"], ["updated_at", "2014-11-17 17:04:12.782044"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:12.783606"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.783606"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-11-17 17:04:12.786396"], ["updated_at", "2014-11-17 17:04:12.787167"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.3ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0004_must create if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.790537"], ["updated_at", "2014-11-17 17:04:12.790537"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.791707"], ["updated_at", "2014-11-17 17:04:12.791707"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.793129"], ["updated_at", "2014-11-17 17:04:12.793129"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:12.794867"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.794867"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:04:12.798383"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.798383"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Another thing"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Another thing' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Another thing"], ["created_at", "2014-11-17 17:04:12.803322"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.803322"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"And this too"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'And this too' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "And this too"], ["created_at", "2014-11-17 17:04:12.807396"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.807396"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0005_won't create if double posting -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.810481"], ["updated_at", "2014-11-17 17:04:12.810481"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.811859"], ["updated_at", "2014-11-17 17:04:12.811859"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.813482"], ["updated_at", "2014-11-17 17:04:12.813482"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:12.815161"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.815161"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:04:12.822292"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.822292"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------- Commontator::CommentsController: test_0006_won't edit unless authorized -----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.829064"], ["updated_at", "2014-11-17 17:04:12.829064"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.830471"], ["updated_at", "2014-11-17 17:04:12.830471"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.832085"], ["updated_at", "2014-11-17 17:04:12.832085"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:12.833685"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.833685"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.838427"], ["updated_at", "2014-11-17 17:04:12.838427"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:04:12.846209"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.846209"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------ Commontator::CommentsController: test_0007_must edit if authorized ------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.851259"], ["updated_at", "2014-11-17 17:04:12.851259"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.852521"], ["updated_at", "2014-11-17 17:04:12.852521"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.853948"], ["updated_at", "2014-11-17 17:04:12.853948"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:12.855530"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.855530"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0008_won't update unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.867546"], ["updated_at", "2014-11-17 17:04:12.867546"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.868796"], ["updated_at", "2014-11-17 17:04:12.868796"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.870353"], ["updated_at", "2014-11-17 17:04:12.870353"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:12.872137"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.872137"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.877399"], ["updated_at", "2014-11-17 17:04:12.877399"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:04:12.882024"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.882024"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0009_must update if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.887243"], ["updated_at", "2014-11-17 17:04:12.887243"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.888588"], ["updated_at", "2014-11-17 17:04:12.888588"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.890072"], ["updated_at", "2014-11-17 17:04:12.890072"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:12.891696"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.891696"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["body", "Something else"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 17:04:12.896687"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------------- Commontator::CommentsController: test_0010_won't delete unless authorized and not deleted -----------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.908475"], ["updated_at", "2014-11-17 17:04:12.908475"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.909798"], ["updated_at", "2014-11-17 17:04:12.909798"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.911354"], ["updated_at", "2014-11-17 17:04:12.911354"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:12.913073"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.913073"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-11-17 17:04:12.919347') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-11-17 17:04:12.919347"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 17:04:12.920986"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:04:12.926255"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.926255"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["updated_at", "2014-11-17 17:04:12.927853"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.4ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------------------ Commontator::CommentsController: test_0011_must delete if authorized and not deleted ------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.933459"], ["updated_at", "2014-11-17 17:04:12.933459"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.935365"], ["updated_at", "2014-11-17 17:04:12.935365"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.937339"], ["updated_at", "2014-11-17 17:04:12.937339"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:12.939301"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.939301"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-11-17 17:04:12.943162') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-11-17 17:04:12.943162"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 17:04:12.944167"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.945948"], ["updated_at", "2014-11-17 17:04:12.945948"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:04:12.947543"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.947543"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["updated_at", "2014-11-17 17:04:12.949069"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-11-17 17:04:12.951063') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-11-17 17:04:12.951063"], ["editor_id", 3], ["updated_at", "2014-11-17 17:04:12.951984"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["editor_id", 2], ["updated_at", "2014-11-17 17:04:12.954201"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-11-17 17:04:12.956188') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-11-17 17:04:12.956188"], ["editor_id", 3], ["updated_at", "2014-11-17 17:04:12.957106"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------------- Commontator::CommentsController: test_0012_won't undelete unless authorized and deleted ---------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.959566"], ["updated_at", "2014-11-17 17:04:12.959566"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.960981"], ["updated_at", "2014-11-17 17:04:12.960981"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.962646"], ["updated_at", "2014-11-17 17:04:12.962646"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:12.964466"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.964466"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-11-17 17:04:12.965185') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-11-17 17:04:12.965185"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 17:04:12.966051"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["updated_at", "2014-11-17 17:04:12.972776"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.976646"], ["updated_at", "2014-11-17 17:04:12.976646"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-11-17 17:04:12.977199') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-11-17 17:04:12.977199"], ["editor_id", 3], ["updated_at", "2014-11-17 17:04:12.978252"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 3]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:04:12.984103"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.984103"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["editor_id", 2], ["updated_at", "2014-11-17 17:04:12.986203"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-11-17 17:04:12.986827') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-11-17 17:04:12.986827"], ["updated_at", "2014-11-17 17:04:12.987622"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.5ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------------------------- Commontator::CommentsController: test_0013_must undelete if authorized and deleted ----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.993564"], ["updated_at", "2014-11-17 17:04:12.993564"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:12.995185"], ["updated_at", "2014-11-17 17:04:12.995185"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:12.996940"], ["updated_at", "2014-11-17 17:04:12.996940"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:12.999405"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:12.999405"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-11-17 17:04:13.000323') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-11-17 17:04:13.000323"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 17:04:13.001426"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["updated_at", "2014-11-17 17:04:13.007047"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.008725"], ["updated_at", "2014-11-17 17:04:13.008725"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:04:13.010288"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:13.010288"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-11-17 17:04:13.010991') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-11-17 17:04:13.010991"], ["updated_at", "2014-11-17 17:04:13.011944"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["editor_id", 3], ["updated_at", "2014-11-17 17:04:13.015182"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-11-17 17:04:13.016456') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", "2014-11-17 17:04:13.016456"], ["editor_id", 2], ["updated_at", "2014-11-17 17:04:13.017282"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 1 [["deleted_at", nil], ["editor_id", 3], ["updated_at", "2014-11-17 17:04:13.020459"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.3ms)  (0.3ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0014_won't upvote unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.025618"], ["updated_at", "2014-11-17 17:04:13.025618"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.026892"], ["updated_at", "2014-11-17 17:04:13.026892"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.028627"], ["updated_at", "2014-11-17 17:04:13.028627"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:13.030368"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:13.030368"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.040152"], ["updated_at", "2014-11-17 17:04:13.040152"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.3ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0015_must upvote if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.045880"], ["updated_at", "2014-11-17 17:04:13.045880"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.047243"], ["updated_at", "2014-11-17 17:04:13.047243"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.048943"], ["updated_at", "2014-11-17 17:04:13.048943"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:13.050619"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:13.050619"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.051497"], ["updated_at", "2014-11-17 17:04:13.051497"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:04:13.059828"], ["updated_at", "2014-11-17 17:04:13.059828"], ["votable_id", 1], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 3], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 10ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-11-17 17:04:13.073391"], ["vote_flag", "f"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-11-17 17:04:13.079141"], ["vote_flag", "t"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------- Commontator::CommentsController: test_0016_won't downvote unless authorized ---------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.085252"], ["updated_at", "2014-11-17 17:04:13.085252"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.086600"], ["updated_at", "2014-11-17 17:04:13.086600"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.088128"], ["updated_at", "2014-11-17 17:04:13.088128"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:13.089734"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:13.089734"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.098157"], ["updated_at", "2014-11-17 17:04:13.098157"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------- Commontator::CommentsController: test_0017_must downvote if authorized ----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.105359"], ["updated_at", "2014-11-17 17:04:13.105359"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.107200"], ["updated_at", "2014-11-17 17:04:13.107200"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.109496"], ["updated_at", "2014-11-17 17:04:13.109496"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:13.111805"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:13.111805"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.112952"], ["updated_at", "2014-11-17 17:04:13.112952"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:04:13.117654"], ["updated_at", "2014-11-17 17:04:13.117654"], ["votable_id", 1], ["votable_type", "Commontator::Comment"], ["vote_flag", "f"], ["vote_weight", 1], ["voter_id", 3], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.4ms)  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-11-17 17:04:13.132277"], ["vote_flag", "t"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-11-17 17:04:13.140149"], ["vote_flag", "f"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0018_won't unvote unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.146090"], ["updated_at", "2014-11-17 17:04:13.146090"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.148046"], ["updated_at", "2014-11-17 17:04:13.148046"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.150466"], ["updated_at", "2014-11-17 17:04:13.150466"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:13.152828"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:13.152828"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 2 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:04:13.155668"], ["updated_at", "2014-11-17 17:04:13.155668"], ["votable_id", 1], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.165355"], ["updated_at", "2014-11-17 17:04:13.165355"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0019_must unvote if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.171091"], ["updated_at", "2014-11-17 17:04:13.171091"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.172357"], ["updated_at", "2014-11-17 17:04:13.172357"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.173826"], ["updated_at", "2014-11-17 17:04:13.173826"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:13.175367"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:13.175367"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.176218"], ["updated_at", "2014-11-17 17:04:13.176218"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:04:13.178383"], ["updated_at", "2014-11-17 17:04:13.178383"], ["votable_id", 1], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 3], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 7ms (ActiveRecord: 0.7ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:04:13.195974"], ["updated_at", "2014-11-17 17:04:13.195974"], ["votable_id", 1], ["votable_type", "Commontator::Comment"], ["vote_flag", "f"], ["vote_weight", 1], ["voter_id", 3], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 3 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 11ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::CommentsController: test_0020_won't send mail if recipients empty ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.213175"], ["updated_at", "2014-11-17 17:04:13.213175"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.214649"], ["updated_at", "2014-11-17 17:04:13.214649"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.216318"], ["updated_at", "2014-11-17 17:04:13.216318"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:13.217995"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:13.217995"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.219009"], ["updated_at", "2014-11-17 17:04:13.219009"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:04:13.222589"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:13.222589"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------------- Commontator::CommentsController: test_0021_must send mail if recipients not empty ---------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.225618"], ["updated_at", "2014-11-17 17:04:13.225618"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.226830"], ["updated_at", "2014-11-17 17:04:13.226830"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.228515"], ["updated_at", "2014-11-17 17:04:13.228515"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:13.230349"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:13.230349"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.231281"], ["updated_at", "2014-11-17 17:04:13.231281"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 1 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 3], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 3) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:04:13.233522"], ["subscriber_id", 3], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:13.233522"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:04:13.237181"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 1], ["updated_at", "2014-11-17 17:04:13.237181"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 3]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.4ms)  (0.3ms) rollback transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.242160"], ["updated_at", "2014-11-17 17:04:13.242160"]]  (0.5ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.244038"], ["updated_at", "2014-11-17 17:04:13.244038"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.246799"], ["updated_at", "2014-11-17 17:04:13.246799"]]  (0.8ms) commit transaction  (0.2ms) begin transaction Commontator::Thread Exists (0.2ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.2ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-11-17 17:04:13.248880"], ["closer_id", 2], ["closer_type", "DummyUser"], ["updated_at", "2014-11-17 17:04:13.250591"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-11-17 17:04:13.252673"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.254124"], ["updated_at", "2014-11-17 17:04:13.254124"]]  (0.6ms) commit transaction  (0.1ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.255921"], ["updated_at", "2014-11-17 17:04:13.255921"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.257377"], ["updated_at", "2014-11-17 17:04:13.257377"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 3 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:13.259719"], ["creator_id", 3], ["creator_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-11-17 17:04:13.259719"]]  (0.5ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 3 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:04:13.262223"], ["creator_id", 3], ["creator_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-11-17 17:04:13.262223"]]  (0.5ms) commit transaction Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY created_at ASC [["thread_id", 2]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.265051"], ["updated_at", "2014-11-17 17:04:13.265051"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.266842"], ["updated_at", "2014-11-17 17:04:13.266842"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 3 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 3], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.268367"], ["updated_at", "2014-11-17 17:04:13.268367"]]  (0.5ms) commit transaction Commontator::Subscription Load (0.2ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 3 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 4], ["subscriber_type", "DummyUser"]]  (0.1ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 3 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 4) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:04:13.272496"], ["subscriber_id", 4], ["subscriber_type", "DummyUser"], ["thread_id", 3], ["updated_at", "2014-11-17 17:04:13.272496"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.274435"], ["updated_at", "2014-11-17 17:04:13.274435"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 3 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 5], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 3 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 5) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:04:13.277457"], ["subscriber_id", 5], ["subscriber_type", "DummyUser"], ["thread_id", 3], ["updated_at", "2014-11-17 17:04:13.277457"]]  (0.5ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 3]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 4]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.280582"], ["updated_at", "2014-11-17 17:04:13.280582"]]  (0.5ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.282339"], ["updated_at", "2014-11-17 17:04:13.282339"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 4]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 4 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 4], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.283840"], ["updated_at", "2014-11-17 17:04:13.283840"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 4 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 6], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 4 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 6) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:04:13.286807"], ["subscriber_id", 6], ["subscriber_type", "DummyUser"], ["thread_id", 4], ["updated_at", "2014-11-17 17:04:13.286807"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 4 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 6], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 4]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 4]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 17:04:13.286807') [["thread_id", 4]]  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 6 AND "commontator_comments"."thread_id" = 4 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:13.291883"], ["creator_id", 6], ["creator_type", "DummyUser"], ["thread_id", 4], ["updated_at", "2014-11-17 17:04:13.291883"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 4]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 4]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 17:04:13.286807') [["thread_id", 4]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 4 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 6], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction SQL (0.2ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-11-17 17:04:13.296079' WHERE "commontator_subscriptions"."id" = 3  (0.5ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 4]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 4]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 17:04:13.296079') [["thread_id", 4]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.299700"], ["updated_at", "2014-11-17 17:04:13.299700"]]  (0.7ms) commit transaction  (0.1ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.301900"], ["updated_at", "2014-11-17 17:04:13.301900"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 5 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 5], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.303497"], ["updated_at", "2014-11-17 17:04:13.303497"]]  (0.6ms) commit transaction  (0.0ms) begin transaction DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 5]] SQL (0.1ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 5 [["commontable_id", nil], ["updated_at", "2014-11-17 17:04:13.305217"]]  (0.6ms) commit transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.307193"], ["updated_at", "2014-11-17 17:04:13.307193"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.309403"], ["updated_at", "2014-11-17 17:04:13.309403"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 6 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 6], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.311114"], ["updated_at", "2014-11-17 17:04:13.311114"]]  (0.5ms) commit transaction Commontator::Subscription Load (0.2ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 6 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 8], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 6 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 8) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:04:13.314598"], ["subscriber_id", 8], ["subscriber_type", "DummyUser"], ["thread_id", 6], ["updated_at", "2014-11-17 17:04:13.314598"]]  (0.7ms) commit transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.316349"], ["updated_at", "2014-11-17 17:04:13.316349"]]  (0.5ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 6 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 9], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 6 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 9) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:04:13.319326"], ["subscriber_id", 9], ["subscriber_type", "DummyUser"], ["thread_id", 6], ["updated_at", "2014-11-17 17:04:13.319326"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 6 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 8], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 6]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 8]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 6 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 9], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 6]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.323972"], ["updated_at", "2014-11-17 17:04:13.323972"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.325718"], ["updated_at", "2014-11-17 17:04:13.325718"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 7]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 7 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 7], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.327327"], ["updated_at", "2014-11-17 17:04:13.327327"]]  (0.5ms) commit transaction  (0.1ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 10 AND "commontator_comments"."thread_id" = 7 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:13.329759"], ["creator_id", 10], ["creator_type", "DummyUser"], ["thread_id", 7], ["updated_at", "2014-11-17 17:04:13.329759"]]  (0.5ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 7 AND "commontator_threads"."id" != 7 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 7 [["closed_at", "2014-11-17 17:04:13.331090"], ["closer_id", 10], ["closer_type", "DummyUser"], ["updated_at", "2014-11-17 17:04:13.331970"]]  (0.5ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 4 LIMIT 1 [["thread_id", 7]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 7]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 7], ["commontable_type", "DummyModel"]]  (0.0ms) begin transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 7]] SQL (0.2ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "commontable_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 7 [["commontable_id", nil], ["commontable_type", nil], ["updated_at", "2014-11-17 17:04:13.336767"]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 7 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 7], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.337988"], ["updated_at", "2014-11-17 17:04:13.337988"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 7]]  (0.6ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 4 LIMIT 1 [["thread_id", 7]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 7]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 7], ["commontable_type", "DummyModel"]] Commontator::Comment Exists (0.0ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 4 LIMIT 1 [["thread_id", 8]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.341944"], ["updated_at", "2014-11-17 17:04:13.341944"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.343788"], ["updated_at", "2014-11-17 17:04:13.343788"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 8]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 8 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 8], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.345492"], ["updated_at", "2014-11-17 17:04:13.345492"]]  (0.5ms) commit transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------- Commontator::Comment: test_0001_must be votable if acts_as_votable is installed -------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.347744"], ["updated_at", "2014-11-17 17:04:13.347744"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.348971"], ["updated_at", "2014-11-17 17:04:13.348971"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.350441"], ["updated_at", "2014-11-17 17:04:13.350441"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.3ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::Comment: test_0002_must know if it has been modified -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.352211"], ["updated_at", "2014-11-17 17:04:13.352211"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.353358"], ["updated_at", "2014-11-17 17:04:13.353358"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.355184"], ["updated_at", "2014-11-17 17:04:13.355184"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:13.356997"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:04:13.356997"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["body", "Something else"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 17:04:13.358576"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.5ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------- Commontator::Comment: test_0003_must know if it has been deleted ----------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.360452"], ["updated_at", "2014-11-17 17:04:13.360452"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.361964"], ["updated_at", "2014-11-17 17:04:13.361964"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.363646"], ["updated_at", "2014-11-17 17:04:13.363646"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-11-17 17:04:13.364597') LIMIT 1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.366039"], ["updated_at", "2014-11-17 17:04:13.366039"]] SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "deleted_at", "editor_id", "editor_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:13.366656"], ["creator_id", 12], ["creator_type", "DummyUser"], ["deleted_at", "2014-11-17 17:04:13.364597"], ["editor_id", 13], ["editor_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:04:13.366656"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-11-17 17:04:13.368840"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------- Commontator::Comment: test_0004_must make proper timestamps -----------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.370650"], ["updated_at", "2014-11-17 17:04:13.370650"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.372034"], ["updated_at", "2014-11-17 17:04:13.372034"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.373662"], ["updated_at", "2014-11-17 17:04:13.373662"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:13.375315"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:04:13.375315"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.377097"], ["updated_at", "2014-11-17 17:04:13.377097"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["body", "Something else"], ["editor_id", 13], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 17:04:13.378624"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------ Commontator::SubscriptionsMailer: test_0001_must create deliverable mail ------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.386074"], ["updated_at", "2014-11-17 17:04:13.386074"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.387380"], ["updated_at", "2014-11-17 17:04:13.387380"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.388896"], ["updated_at", "2014-11-17 17:04:13.388896"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.389741"], ["updated_at", "2014-11-17 17:04:13.389741"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:04:13.391854"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:04:13.391854"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 13], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 13) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:04:13.393806"], ["subscriber_id", 13], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:04:13.393806"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:13.395541"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:04:13.395541"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 13]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/comments/_body.html.erb (6.7ms) Commontator::SubscriptionsMailer#comment_created: processed outbound mail in 18.4ms Sent mail to Undisclosed Recipients (5.0ms) Date: Mon, 17 Nov 2014 11:04:13 -0600 From: no-reply@dummy.com to: Undisclosed Recipients Message-ID: <546a2a8d6641f_5ae53fffa4c2dbdc93687@Dantes-MacBook-Pro.local.mail> Subject: Dummy User #12 posted a comment on DummyModel #9 Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit

Dummy User #12 commented on DummyModel #9:

Something

Click here to view all comments on DummyModel #9.

 (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------- Commontator::Subscription: test_0001_must count unread comments ---------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.426068"], ["updated_at", "2014-11-17 17:04:13.426068"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.427600"], ["updated_at", "2014-11-17 17:04:13.427600"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.429372"], ["updated_at", "2014-11-17 17:04:13.429372"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:04:13.431070"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:04:13.431070"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 17:04:13.431070') [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:04:13.433475"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:04:13.433475"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 17:04:13.431070') [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:04:13.437097"], ["creator_id", 12], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:04:13.437097"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 17:04:13.431070') [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-11-17 17:04:13.439723' WHERE "commontator_subscriptions"."id" = 6  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 17:04:13.439723') [["thread_id", 10]]  (0.4ms) rollback transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:04:13.444098"], ["updated_at", "2014-11-17 17:04:13.444098"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:04:13.446283"], ["updated_at", "2014-11-17 17:04:13.446283"]]  (0.6ms) commit transaction  (1.7ms) CREATE TABLE "commontator_comments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "creator_type" varchar(255), "creator_id" integer, "editor_type" varchar(255), "editor_id" integer, "thread_id" integer NOT NULL, "body" text NOT NULL, "deleted_at" datetime, "cached_votes_up" integer DEFAULT 0, "cached_votes_down" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime)   (0.1ms) select sqlite_version(*)  (0.8ms) CREATE INDEX "index_commontator_comments_on_cached_votes_down" ON "commontator_comments" ("cached_votes_down")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'  (0.8ms) CREATE INDEX "index_commontator_comments_on_cached_votes_up" ON "commontator_comments" ("cached_votes_up")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_comments_on_c_id_and_c_type_and_t_id" ON "commontator_comments" ("creator_id", "creator_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_comments_on_thread_id_and_created_at" ON "commontator_comments" ("thread_id", "created_at")  (0.8ms) CREATE TABLE "commontator_subscriptions" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "subscriber_type" varchar(255) NOT NULL, "subscriber_id" integer NOT NULL, "thread_id" integer NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE UNIQUE INDEX "index_commontator_subscriptions_on_s_id_and_s_type_and_t_id" ON "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_subscriptions_on_thread_id" ON "commontator_subscriptions" ("thread_id")  (0.8ms) CREATE TABLE "commontator_threads" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "commontable_type" varchar(255), "commontable_id" integer, "closed_at" datetime, "closer_type" varchar(255), "closer_id" integer, "created_at" datetime, "updated_at" datetime)   (0.7ms) CREATE UNIQUE INDEX "index_commontator_threads_on_c_id_and_c_type" ON "commontator_threads" ("commontable_id", "commontable_type")  (0.8ms) CREATE TABLE "dummy_models" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE TABLE "dummy_users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)  (0.8ms) CREATE TABLE "votes" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "votable_id" integer, "votable_type" varchar(255), "voter_id" integer, "voter_type" varchar(255), "vote_flag" boolean, "vote_scope" varchar(255), "vote_weight" integer, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE INDEX "index_votes_on_votable_id_and_votable_type_and_vote_scope" ON "votes" ("votable_id", "votable_type", "vote_scope")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index'   (0.9ms) CREATE INDEX "index_votes_on_voter_id_and_voter_type_and_vote_scope" ON "votes" ("voter_id", "voter_type", "vote_scope")  (0.8ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)   (0.8ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.1ms) SELECT version FROM "schema_migrations"  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('3')  (0.6ms) INSERT INTO "schema_migrations" (version) VALUES ('1')  (0.6ms) INSERT INTO "schema_migrations" (version) VALUES ('2')  (0.6ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.0ms) begin transaction SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.792545"], ["updated_at", "2014-11-17 17:06:52.792545"]]  (1.4ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.812056"], ["updated_at", "2014-11-17 17:06:52.812056"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 1], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:52.819693"], ["updated_at", "2014-11-17 17:06:52.819693"]]  (0.7ms) commit transaction  (0.1ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.3ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", "2014-11-17 17:06:52.821281"], ["closer_id", 1], ["closer_type", "DummyUser"], ["updated_at", "2014-11-17 17:06:52.822963"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 1 [["closed_at", nil], ["updated_at", "2014-11-17 17:06:52.826498"]]  (0.4ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.827971"], ["updated_at", "2014-11-17 17:06:52.827971"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.829946"], ["updated_at", "2014-11-17 17:06:52.829946"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.0ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:52.831335"], ["updated_at", "2014-11-17 17:06:52.831335"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:52.839789"], ["creator_id", 2], ["creator_type", "DummyUser"], ["thread_id", 2], ["updated_at", "2014-11-17 17:06:52.839789"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 2 [["closed_at", "2014-11-17 17:06:52.841237"], ["closer_id", 2], ["closer_type", "DummyUser"], ["updated_at", "2014-11-17 17:06:52.842044"]]  (0.6ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 1 LIMIT 1 [["thread_id", 2]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 2], ["commontable_type", "DummyModel"]]  (0.0ms) begin transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] SQL (0.2ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "commontable_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 2 [["commontable_id", nil], ["commontable_type", nil], ["updated_at", "2014-11-17 17:06:52.849809"]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:52.850964"], ["updated_at", "2014-11-17 17:06:52.850964"]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 2]]  (0.7ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 1 LIMIT 1 [["thread_id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 2], ["commontable_type", "DummyModel"]] Commontator::Comment Exists (0.0ms) SELECT 1 AS one FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = 1 LIMIT 1 [["thread_id", 3]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.855634"], ["updated_at", "2014-11-17 17:06:52.855634"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.857442"], ["updated_at", "2014-11-17 17:06:52.857442"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 3 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 3], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:52.858999"], ["updated_at", "2014-11-17 17:06:52.858999"]]  (0.6ms) commit transaction  (0.1ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 3 AND "commontator_comments"."thread_id" = 4 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:52.861367"], ["creator_id", 3], ["creator_type", "DummyUser"], ["thread_id", 4], ["updated_at", "2014-11-17 17:06:52.861367"]]  (0.6ms) commit transaction  (0.1ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 3 AND "commontator_comments"."thread_id" = 4 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:06:52.863953"], ["creator_id", 3], ["creator_type", "DummyUser"], ["thread_id", 4], ["updated_at", "2014-11-17 17:06:52.863953"]]  (0.6ms) commit transaction Commontator::Comment Load (0.2ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 4]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY created_at ASC [["thread_id", 4]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.867046"], ["updated_at", "2014-11-17 17:06:52.867046"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.868812"], ["updated_at", "2014-11-17 17:06:52.868812"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 4]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 4 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 4], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:52.870256"], ["updated_at", "2014-11-17 17:06:52.870256"]]  (0.7ms) commit transaction  (0.1ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.871925"], ["updated_at", "2014-11-17 17:06:52.871925"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.873633"], ["updated_at", "2014-11-17 17:06:52.873633"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 5 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 5], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:52.875952"], ["updated_at", "2014-11-17 17:06:52.875952"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 6 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 5], ["subscriber_type", "DummyUser"]]  (0.1ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 6 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 5) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:06:52.884088"], ["subscriber_id", 5], ["subscriber_type", "DummyUser"], ["thread_id", 6], ["updated_at", "2014-11-17 17:06:52.884088"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 6 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 5], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 6]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 5]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 17:06:52.884088') [["thread_id", 6]]  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 5 AND "commontator_comments"."thread_id" = 6 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:52.889236"], ["creator_id", 5], ["creator_type", "DummyUser"], ["thread_id", 6], ["updated_at", "2014-11-17 17:06:52.889236"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 6]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 17:06:52.884088') [["thread_id", 6]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 6 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 5], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction SQL (0.1ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-11-17 17:06:52.893047' WHERE "commontator_subscriptions"."id" = 1  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 6]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 5]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 17:06:52.893047') [["thread_id", 6]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.896359"], ["updated_at", "2014-11-17 17:06:52.896359"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.898178"], ["updated_at", "2014-11-17 17:06:52.898178"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 6 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 6], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:52.899598"], ["updated_at", "2014-11-17 17:06:52.899598"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 7 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 6], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 7 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 6) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:06:52.902446"], ["subscriber_id", 6], ["subscriber_type", "DummyUser"], ["thread_id", 7], ["updated_at", "2014-11-17 17:06:52.902446"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.903936"], ["updated_at", "2014-11-17 17:06:52.903936"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 7 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 7], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 7 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 7) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:06:52.906418"], ["subscriber_id", 7], ["subscriber_type", "DummyUser"], ["thread_id", 7], ["updated_at", "2014-11-17 17:06:52.906418"]]  (0.8ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 7]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 6]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 7]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.910888"], ["updated_at", "2014-11-17 17:06:52.910888"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.912744"], ["updated_at", "2014-11-17 17:06:52.912744"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 7]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 7 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 7], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:52.914179"], ["updated_at", "2014-11-17 17:06:52.914179"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 8 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 8], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 8 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 8) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:06:52.917171"], ["subscriber_id", 8], ["subscriber_type", "DummyUser"], ["thread_id", 8], ["updated_at", "2014-11-17 17:06:52.917171"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.918647"], ["updated_at", "2014-11-17 17:06:52.918647"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 8 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 9], ["subscriber_type", "DummyUser"]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 8 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 9) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:06:52.921265"], ["subscriber_id", 9], ["subscriber_type", "DummyUser"], ["thread_id", 8], ["updated_at", "2014-11-17 17:06:52.921265"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 8 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 8], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 8]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 8]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 8 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 9], ["subscriber_type", "DummyUser"]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 8]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 9]]  (0.1ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.925128"], ["updated_at", "2014-11-17 17:06:52.925128"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.927043"], ["updated_at", "2014-11-17 17:06:52.927043"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 8]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 8 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 8], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:52.928631"], ["updated_at", "2014-11-17 17:06:52.928631"]]  (0.6ms) commit transaction  (0.0ms) begin transaction DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 8]] SQL (0.1ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 9 [["commontable_id", nil], ["updated_at", "2014-11-17 17:06:52.930399"]]  (0.6ms) commit transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::SharedHelper: test_0001_must show commontator thread -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.937515"], ["updated_at", "2014-11-17 17:06:52.937515"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:52.939117"], ["updated_at", "2014-11-17 17:06:52.939117"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Rendered /Users/dante/Desktop/commontator/app/views/commontator/shared/_thread.html.erb (1.4ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------ Commontator::SubscriptionsMailer: test_0001_must create deliverable mail ------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.951278"], ["updated_at", "2014-11-17 17:06:52.951278"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.953269"], ["updated_at", "2014-11-17 17:06:52.953269"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:52.955116"], ["updated_at", "2014-11-17 17:06:52.955116"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.956042"], ["updated_at", "2014-11-17 17:06:52.956042"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 11) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:06:52.958325"], ["subscriber_id", 11], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:52.958325"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (5.6ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:06:52.966210"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:52.966210"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:52.968006"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:52.968006"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/comments/_body.html.erb (2.2ms) Commontator::SubscriptionsMailer#comment_created: processed outbound mail in 14.6ms Sent mail to Undisclosed Recipients (4.6ms) Date: Mon, 17 Nov 2014 11:06:52 -0600 From: no-reply@dummy.com to: Undisclosed Recipients Message-ID: <546a2b2cf10f6_5b0d3fbfa942dbe88422f@Dantes-MacBook-Pro.local.mail> Subject: Dummy User #11 posted a comment on DummyModel #9 Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit

Dummy User #11 commented on DummyModel #9:

Something

Click here to view all comments on DummyModel #9.

 (0.6ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0001_won't subscribe unless authorized ---------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.996895"], ["updated_at", "2014-11-17 17:06:52.996895"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:52.999209"], ["updated_at", "2014-11-17 17:06:52.999209"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.001582"], ["updated_at", "2014-11-17 17:06:53.001582"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 11) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:06:53.009331"], ["subscriber_id", 11], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.009331"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0002_must subscribe if authorized ----------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.014254"], ["updated_at", "2014-11-17 17:06:53.014254"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.015491"], ["updated_at", "2014-11-17 17:06:53.015491"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.017021"], ["updated_at", "2014-11-17 17:06:53.017021"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 11) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:06:53.020330"], ["subscriber_id", 11], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.020330"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 6]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 11) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:06:53.025282"], ["subscriber_id", 11], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.025282"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 7]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 11) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:06:53.030120"], ["subscriber_id", 11], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.030120"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0003_won't unsubscribe unless authorized -----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.033054"], ["updated_at", "2014-11-17 17:06:53.033054"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.034257"], ["updated_at", "2014-11-17 17:06:53.034257"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.035689"], ["updated_at", "2014-11-17 17:06:53.035689"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 11) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:06:53.037582"], ["subscriber_id", 11], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.037582"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 6]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::SubscriptionsController: test_0004_must unsubscribe if authorized ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.046428"], ["updated_at", "2014-11-17 17:06:53.046428"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.047753"], ["updated_at", "2014-11-17 17:06:53.047753"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.049282"], ["updated_at", "2014-11-17 17:06:53.049282"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 11) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:06:53.051229"], ["subscriber_id", 11], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.051229"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 6]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 11) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:06:53.056427"], ["subscriber_id", 11], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.056427"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 7]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 11) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:06:53.061097"], ["subscriber_id", 11], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.061097"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 8]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------------- Commontator::CommentsController: test_0001_won't get new unless authorized --------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.066698"], ["updated_at", "2014-11-17 17:06:53.066698"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.068202"], ["updated_at", "2014-11-17 17:06:53.068202"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.069717"], ["updated_at", "2014-11-17 17:06:53.069717"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.071307"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.071307"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------- Commontator::CommentsController: test_0002_must get new if authorized ---------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.079443"], ["updated_at", "2014-11-17 17:06:53.079443"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.080765"], ["updated_at", "2014-11-17 17:06:53.080765"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.082262"], ["updated_at", "2014-11-17 17:06:53.082262"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.084007"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.084007"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 1ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 1ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0003_won't create unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.092067"], ["updated_at", "2014-11-17 17:06:53.092067"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.093292"], ["updated_at", "2014-11-17 17:06:53.093292"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.094725"], ["updated_at", "2014-11-17 17:06:53.094725"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.096231"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.096231"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 10 [["closed_at", "2014-11-17 17:06:53.098956"], ["updated_at", "2014-11-17 17:06:53.099618"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0004_must create if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.103173"], ["updated_at", "2014-11-17 17:06:53.103173"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.104352"], ["updated_at", "2014-11-17 17:06:53.104352"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.105748"], ["updated_at", "2014-11-17 17:06:53.105748"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.107264"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.107264"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:06:53.110377"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.110377"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Another thing"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.3ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Another thing' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Another thing"], ["created_at", "2014-11-17 17:06:53.115003"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.115003"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.6ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"And this too"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'And this too' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "And this too"], ["created_at", "2014-11-17 17:06:53.119279"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.119279"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0005_won't create if double posting -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.122503"], ["updated_at", "2014-11-17 17:06:53.122503"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.123810"], ["updated_at", "2014-11-17 17:06:53.123810"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.125855"], ["updated_at", "2014-11-17 17:06:53.125855"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.127579"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.127579"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something"}} Commontator::Thread Load (5.4ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 9ms (ActiveRecord: 5.6ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:06:53.140808"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.140808"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------- Commontator::CommentsController: test_0006_won't edit unless authorized -----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.147285"], ["updated_at", "2014-11-17 17:06:53.147285"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.148567"], ["updated_at", "2014-11-17 17:06:53.148567"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.150123"], ["updated_at", "2014-11-17 17:06:53.150123"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.151678"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.151678"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.2ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.156124"], ["updated_at", "2014-11-17 17:06:53.156124"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:06:53.160421"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.160421"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------ Commontator::CommentsController: test_0007_must edit if authorized ------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.165309"], ["updated_at", "2014-11-17 17:06:53.165309"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.166530"], ["updated_at", "2014-11-17 17:06:53.166530"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.167993"], ["updated_at", "2014-11-17 17:06:53.167993"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.169615"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.169615"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.3ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0008_won't update unless authorized -------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.181173"], ["updated_at", "2014-11-17 17:06:53.181173"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.182371"], ["updated_at", "2014-11-17 17:06:53.182371"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.183870"], ["updated_at", "2014-11-17 17:06:53.183870"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.185436"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.185436"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.190456"], ["updated_at", "2014-11-17 17:06:53.190456"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:06:53.194199"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.194199"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.5ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0009_must update if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.199152"], ["updated_at", "2014-11-17 17:06:53.199152"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.201388"], ["updated_at", "2014-11-17 17:06:53.201388"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.203720"], ["updated_at", "2014-11-17 17:06:53.203720"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.206043"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.206043"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["body", "Something else"], ["editor_id", 11], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 17:06:53.211897"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 5ms (ActiveRecord: 0.5ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------------------------------- Commontator::CommentsController: test_0010_won't delete unless authorized and not deleted -----------------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.223346"], ["updated_at", "2014-11-17 17:06:53.223346"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.225547"], ["updated_at", "2014-11-17 17:06:53.225547"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.227851"], ["updated_at", "2014-11-17 17:06:53.227851"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.230176"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.230176"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-11-17 17:06:53.235900') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 17:06:53.235900"], ["editor_id", 11], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 17:06:53.237192"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:06:53.242146"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.242146"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-11-17 17:06:53.243561"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------------ Commontator::CommentsController: test_0011_must delete if authorized and not deleted ------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.247977"], ["updated_at", "2014-11-17 17:06:53.247977"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.249163"], ["updated_at", "2014-11-17 17:06:53.249163"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.250648"], ["updated_at", "2014-11-17 17:06:53.250648"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.252173"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.252173"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-11-17 17:06:53.255639') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 17:06:53.255639"], ["editor_id", 11], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 17:06:53.256627"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.258474"], ["updated_at", "2014-11-17 17:06:53.258474"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:06:53.260648"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.260648"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-11-17 17:06:53.262131"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-11-17 17:06:53.264346') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 17:06:53.264346"], ["editor_id", 12], ["updated_at", "2014-11-17 17:06:53.265298"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 11], ["updated_at", "2014-11-17 17:06:53.267390"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-11-17 17:06:53.269340') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 17:06:53.269340"], ["editor_id", 12], ["updated_at", "2014-11-17 17:06:53.270244"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------------- Commontator::CommentsController: test_0012_won't undelete unless authorized and deleted ---------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.272738"], ["updated_at", "2014-11-17 17:06:53.272738"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.273991"], ["updated_at", "2014-11-17 17:06:53.273991"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.275394"], ["updated_at", "2014-11-17 17:06:53.275394"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.276960"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.276960"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-11-17 17:06:53.277574') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 17:06:53.277574"], ["editor_id", 11], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 17:06:53.278378"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-11-17 17:06:53.284543"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.288447"], ["updated_at", "2014-11-17 17:06:53.288447"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-11-17 17:06:53.289006') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 17:06:53.289006"], ["editor_id", 12], ["updated_at", "2014-11-17 17:06:53.289877"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:06:53.293716"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.293716"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 11], ["updated_at", "2014-11-17 17:06:53.295604"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-11-17 17:06:53.296082') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 17:06:53.296082"], ["updated_at", "2014-11-17 17:06:53.296848"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------------------- Commontator::CommentsController: test_0013_must undelete if authorized and deleted ----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.301807"], ["updated_at", "2014-11-17 17:06:53.301807"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.302999"], ["updated_at", "2014-11-17 17:06:53.302999"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.310283"], ["updated_at", "2014-11-17 17:06:53.310283"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.312402"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.312402"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-11-17 17:06:53.313161') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 17:06:53.313161"], ["editor_id", 11], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 17:06:53.314053"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-11-17 17:06:53.319003"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 5ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.320633"], ["updated_at", "2014-11-17 17:06:53.320633"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:06:53.322112"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.322112"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-11-17 17:06:53.322719') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 17:06:53.322719"], ["updated_at", "2014-11-17 17:06:53.323507"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 12], ["updated_at", "2014-11-17 17:06:53.326309"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-11-17 17:06:53.327465') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", "2014-11-17 17:06:53.327465"], ["editor_id", 11], ["updated_at", "2014-11-17 17:06:53.328286"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["editor_id", 12], ["updated_at", "2014-11-17 17:06:53.331064"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0014_won't upvote unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.333430"], ["updated_at", "2014-11-17 17:06:53.333430"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.334720"], ["updated_at", "2014-11-17 17:06:53.334720"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.336231"], ["updated_at", "2014-11-17 17:06:53.336231"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.337806"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.337806"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.346700"], ["updated_at", "2014-11-17 17:06:53.346700"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0015_must upvote if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.352127"], ["updated_at", "2014-11-17 17:06:53.352127"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.353437"], ["updated_at", "2014-11-17 17:06:53.353437"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.354929"], ["updated_at", "2014-11-17 17:06:53.354929"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.356483"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.356483"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.357363"], ["updated_at", "2014-11-17 17:06:53.357363"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:06:53.365601"], ["updated_at", "2014-11-17 17:06:53.365601"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 12], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 10ms (ActiveRecord: 0.7ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-11-17 17:06:53.379961"], ["vote_flag", "f"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-11-17 17:06:53.385650"], ["vote_flag", "t"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------- Commontator::CommentsController: test_0016_won't downvote unless authorized ---------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.390912"], ["updated_at", "2014-11-17 17:06:53.390912"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.392213"], ["updated_at", "2014-11-17 17:06:53.392213"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.393713"], ["updated_at", "2014-11-17 17:06:53.393713"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.395291"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.395291"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.402378"], ["updated_at", "2014-11-17 17:06:53.402378"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------- Commontator::CommentsController: test_0017_must downvote if authorized ----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.407644"], ["updated_at", "2014-11-17 17:06:53.407644"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.408835"], ["updated_at", "2014-11-17 17:06:53.408835"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.410284"], ["updated_at", "2014-11-17 17:06:53.410284"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.411863"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.411863"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.412733"], ["updated_at", "2014-11-17 17:06:53.412733"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:06:53.416842"], ["updated_at", "2014-11-17 17:06:53.416842"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "f"], ["vote_weight", 1], ["voter_id", 12], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-11-17 17:06:53.430332"], ["vote_flag", "t"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "updated_at" = ?, "vote_flag" = ? WHERE "votes"."id" = 1 [["updated_at", "2014-11-17 17:06:53.435991"], ["vote_flag", "f"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0018_won't unvote unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.441052"], ["updated_at", "2014-11-17 17:06:53.441052"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.442370"], ["updated_at", "2014-11-17 17:06:53.442370"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.443891"], ["updated_at", "2014-11-17 17:06:53.443891"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.445468"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.445468"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 11 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:06:53.447477"], ["updated_at", "2014-11-17 17:06:53.447477"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 11], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.456297"], ["updated_at", "2014-11-17 17:06:53.456297"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0019_must unvote if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.461805"], ["updated_at", "2014-11-17 17:06:53.461805"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.463056"], ["updated_at", "2014-11-17 17:06:53.463056"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.464610"], ["updated_at", "2014-11-17 17:06:53.464610"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.466299"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.466299"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.467241"], ["updated_at", "2014-11-17 17:06:53.467241"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:06:53.474333"], ["updated_at", "2014-11-17 17:06:53.474333"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "t"], ["vote_weight", 1], ["voter_id", 12], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.7ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.1ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("created_at", "updated_at", "votable_id", "votable_type", "vote_flag", "vote_weight", "voter_id", "voter_type") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:06:53.490284"], ["updated_at", "2014-11-17 17:06:53.490284"], ["votable_id", 5], ["votable_type", "Commontator::Comment"], ["vote_flag", "f"], ["vote_weight", 1], ["voter_id", 12], ["voter_type", "DummyUser"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = 5 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 11]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = 12 AND "votes"."vote_scope" IS NULL AND "votes"."voter_type" = 'DummyUser' [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = 5  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::CommentsController: test_0020_won't send mail if recipients empty ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.501947"], ["updated_at", "2014-11-17 17:06:53.501947"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.503318"], ["updated_at", "2014-11-17 17:06:53.503318"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.504878"], ["updated_at", "2014-11-17 17:06:53.504878"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.506474"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.506474"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.507379"], ["updated_at", "2014-11-17 17:06:53.507379"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:06:53.510585"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.510585"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------- Commontator::CommentsController: test_0021_must send mail if recipients not empty ---------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.513673"], ["updated_at", "2014-11-17 17:06:53.513673"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.514875"], ["updated_at", "2014-11-17 17:06:53.514875"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.516341"], ["updated_at", "2014-11-17 17:06:53.516341"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.517884"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.517884"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.518744"], ["updated_at", "2014-11-17 17:06:53.518744"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 10 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:06:53.520705"], ["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.520705"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"10", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:06:53.523968"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.523968"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.4ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------- Commontator::Comment: test_0001_must be votable if acts_as_votable is installed -------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.527856"], ["updated_at", "2014-11-17 17:06:53.527856"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.529100"], ["updated_at", "2014-11-17 17:06:53.529100"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.530588"], ["updated_at", "2014-11-17 17:06:53.530588"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.3ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::Comment: test_0002_must know if it has been modified -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.532336"], ["updated_at", "2014-11-17 17:06:53.532336"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.533457"], ["updated_at", "2014-11-17 17:06:53.533457"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.534807"], ["updated_at", "2014-11-17 17:06:53.534807"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.536555"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.536555"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["body", "Something else"], ["editor_id", 11], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 17:06:53.538025"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.3ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------- Commontator::Comment: test_0003_must know if it has been deleted ----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.539537"], ["updated_at", "2014-11-17 17:06:53.539537"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.540727"], ["updated_at", "2014-11-17 17:06:53.540727"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.542819"], ["updated_at", "2014-11-17 17:06:53.542819"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-11-17 17:06:53.543781') LIMIT 1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.544784"], ["updated_at", "2014-11-17 17:06:53.544784"]] SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "deleted_at", "editor_id", "editor_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.545314"], ["creator_id", 11], ["creator_type", "DummyUser"], ["deleted_at", "2014-11-17 17:06:53.543781"], ["editor_id", 12], ["editor_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.545314"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["deleted_at", nil], ["updated_at", "2014-11-17 17:06:53.546865"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------- Commontator::Comment: test_0004_must make proper timestamps -----------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.548340"], ["updated_at", "2014-11-17 17:06:53.548340"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.549511"], ["updated_at", "2014-11-17 17:06:53.549511"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.551010"], ["updated_at", "2014-11-17 17:06:53.551010"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.552556"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 10], ["updated_at", "2014-11-17 17:06:53.552556"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.554159"], ["updated_at", "2014-11-17 17:06:53.554159"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = 5 [["body", "Something else"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-11-17 17:06:53.555468"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::ApplicationHelper: test_0001_must print javascript proc --------------------------------------------------------------------  (0.0ms) rollback transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.559730"], ["updated_at", "2014-11-17 17:06:53.559730"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.561220"], ["updated_at", "2014-11-17 17:06:53.561220"]]  (0.7ms) commit transaction  (0.0ms) begin transaction ---------------------------------------------------------------------- Commontator::ThreadsController: test_0001_won't show unless authorized ----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.565226"], ["updated_at", "2014-11-17 17:06:53.565226"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.566386"], ["updated_at", "2014-11-17 17:06:53.566386"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.567848"], ["updated_at", "2014-11-17 17:06:53.567848"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------- Commontator::ThreadsController: test_0002_must show if authorized -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.573491"], ["updated_at", "2014-11-17 17:06:53.573491"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.575789"], ["updated_at", "2014-11-17 17:06:53.575789"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.578219"], ["updated_at", "2014-11-17 17:06:53.578219"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 10], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/10 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 10], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 10], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = 11 ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 11], ["subscriber_type", "DummyUser"]] Redirected to http://test.host/dummy_models/10 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------------------- Commontator::ThreadsController: test_0003_won't close unless authorized and open --------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.591416"], ["updated_at", "2014-11-17 17:06:53.591416"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.593676"], ["updated_at", "2014-11-17 17:06:53.593676"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.596028"], ["updated_at", "2014-11-17 17:06:53.596028"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"11"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 11 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 11 [["closed_at", "2014-11-17 17:06:53.602227"], ["updated_at", "2014-11-17 17:06:53.602990"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------- Commontator::ThreadsController: test_0004_must close if authorized and open ---------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.606781"], ["updated_at", "2014-11-17 17:06:53.606781"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.608109"], ["updated_at", "2014-11-17 17:06:53.608109"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.610317"], ["updated_at", "2014-11-17 17:06:53.610317"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 11 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 11 [["closed_at", "2014-11-17 17:06:53.612500"], ["closer_id", 11], ["closer_type", "DummyUser"], ["updated_at", "2014-11-17 17:06:53.613243"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 11 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 11 [["closed_at", nil], ["updated_at", "2014-11-17 17:06:53.615422"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 11 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 11 [["closed_at", "2014-11-17 17:06:53.617016"], ["updated_at", "2014-11-17 17:06:53.617703"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------- Commontator::ThreadsController: test_0005_won't reopen unless authorized and closed -----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.620164"], ["updated_at", "2014-11-17 17:06:53.620164"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.621384"], ["updated_at", "2014-11-17 17:06:53.621384"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.622840"], ["updated_at", "2014-11-17 17:06:53.622840"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 11 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 11 [["closed_at", "2014-11-17 17:06:53.623410"], ["updated_at", "2014-11-17 17:06:53.623984"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"11"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 11 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 11 [["closed_at", nil], ["updated_at", "2014-11-17 17:06:53.629523"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::ThreadsController: test_0006_must reopen if authorized and closed ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.633112"], ["updated_at", "2014-11-17 17:06:53.633112"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.634351"], ["updated_at", "2014-11-17 17:06:53.634351"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.635840"], ["updated_at", "2014-11-17 17:06:53.635840"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 11 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 11 [["closed_at", "2014-11-17 17:06:53.636445"], ["updated_at", "2014-11-17 17:06:53.637034"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 11 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 11 [["closed_at", nil], ["updated_at", "2014-11-17 17:06:53.639631"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 2ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 11 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 11 [["closed_at", "2014-11-17 17:06:53.640951"], ["updated_at", "2014-11-17 17:06:53.641560"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 11 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = 11 [["closed_at", nil], ["updated_at", "2014-11-17 17:06:53.643825"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 8ms (ActiveRecord: 0.3ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------- Commontator::Subscription: test_0001_must count unread comments ---------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.652025"], ["updated_at", "2014-11-17 17:06:53.652025"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.653418"], ["updated_at", "2014-11-17 17:06:53.653418"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 10], ["commontable_type", "DummyModel"], ["created_at", "2014-11-17 17:06:53.655107"], ["updated_at", "2014-11-17 17:06:53.655107"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 11 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 11) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("created_at", "subscriber_id", "subscriber_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?) [["created_at", "2014-11-17 17:06:53.656577"], ["subscriber_id", 11], ["subscriber_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 17:06:53.656577"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 17:06:53.656577') [["thread_id", 11]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something"], ["created_at", "2014-11-17 17:06:53.659514"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 17:06:53.659514"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 17:06:53.656577') [["thread_id", 11]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 11 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("body", "created_at", "creator_id", "creator_type", "thread_id", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["body", "Something else"], ["created_at", "2014-11-17 17:06:53.662997"], ["creator_id", 11], ["creator_type", "DummyUser"], ["thread_id", 11], ["updated_at", "2014-11-17 17:06:53.662997"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 17:06:53.656577') [["thread_id", 11]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-11-17 17:06:53.665451' WHERE "commontator_subscriptions"."id" = 6  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-11-17 17:06:53.665451') [["thread_id", 11]]  (0.4ms) rollback transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-11-17 17:06:53.670123"], ["updated_at", "2014-11-17 17:06:53.670123"]]  (0.6ms) commit transaction  (1.0ms) CREATE TABLE "commontator_comments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "creator_type" varchar, "creator_id" integer, "editor_type" varchar, "editor_id" integer, "thread_id" integer NOT NULL, "body" text NOT NULL, "deleted_at" datetime, "cached_votes_up" integer DEFAULT 0, "cached_votes_down" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime)   (0.1ms) select sqlite_version(*)  (0.5ms) CREATE INDEX "index_commontator_comments_on_cached_votes_down" ON "commontator_comments" ("cached_votes_down")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'  (0.5ms) CREATE INDEX "index_commontator_comments_on_cached_votes_up" ON "commontator_comments" ("cached_votes_up")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.5ms) CREATE INDEX "index_commontator_comments_on_c_id_and_c_type_and_t_id" ON "commontator_comments" ("creator_id", "creator_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.5ms) CREATE INDEX "index_commontator_comments_on_thread_id_and_created_at" ON "commontator_comments" ("thread_id", "created_at")  (0.5ms) CREATE TABLE "commontator_subscriptions" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "subscriber_type" varchar NOT NULL, "subscriber_id" integer NOT NULL, "thread_id" integer NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.5ms) CREATE UNIQUE INDEX "index_commontator_subscriptions_on_s_id_and_s_type_and_t_id" ON "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index'   (4.8ms) CREATE INDEX "index_commontator_subscriptions_on_thread_id" ON "commontator_subscriptions" ("thread_id")  (0.9ms) CREATE TABLE "commontator_threads" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "commontable_type" varchar, "commontable_id" integer, "closed_at" datetime, "closer_type" varchar, "closer_id" integer, "created_at" datetime, "updated_at" datetime)   (0.9ms) CREATE UNIQUE INDEX "index_commontator_threads_on_c_id_and_c_type" ON "commontator_threads" ("commontable_id", "commontable_type")  (0.7ms) CREATE TABLE "dummy_models" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.7ms) CREATE TABLE "dummy_users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)  (0.7ms) CREATE TABLE "votes" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "votable_id" integer, "votable_type" varchar, "voter_id" integer, "voter_type" varchar, "vote_flag" boolean, "vote_scope" varchar, "vote_weight" integer, "created_at" datetime, "updated_at" datetime)   (0.7ms) CREATE INDEX "index_votes_on_votable_id_and_votable_type_and_vote_scope" ON "votes" ("votable_id", "votable_type", "vote_scope")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index'   (0.7ms) CREATE INDEX "index_votes_on_voter_id_and_voter_type_and_vote_scope" ON "votes" ("voter_id", "voter_type", "vote_scope")  (0.8ms) CREATE TABLE "schema_migrations" ("version" varchar NOT NULL)   (0.8ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.1ms) SELECT version FROM "schema_migrations"  (0.8ms) INSERT INTO "schema_migrations" (version) VALUES ('3')  (0.8ms) INSERT INTO "schema_migrations" (version) VALUES ('1')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('2')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.1ms) begin transaction ---------------------------------------------------------------------- Commontator::ThreadsController: test_0001_won't show unless authorized ----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.590098"], ["updated_at", "2014-12-23 15:22:18.590098"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.9ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.607177"], ["updated_at", "2014-12-23 15:22:18.607177"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:18.616930"], ["updated_at", "2014-12-23 15:22:18.616930"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.1ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::ThreadsController: test_0002_must show if authorized -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.627806"], ["updated_at", "2014-12-23 15:22:18.627806"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.629472"], ["updated_at", "2014-12-23 15:22:18.629472"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:18.631163"], ["updated_at", "2014-12-23 15:22:18.631163"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 1], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Redirected to http://test.host/dummy_models/1 Completed 302 Found in 10ms (ActiveRecord: 0.4ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 1], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Redirected to http://test.host/dummy_models/1 Completed 302 Found in 3ms (ActiveRecord: 0.1ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 1], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Redirected to http://test.host/dummy_models/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------------------- Commontator::ThreadsController: test_0003_won't close unless authorized and open --------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.654392"], ["updated_at", "2014-12-23 15:22:18.654392"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.657273"], ["updated_at", "2014-12-23 15:22:18.657273"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:18.660038"], ["updated_at", "2014-12-23 15:22:18.660038"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:22:18.666486"], ["updated_at", "2014-12-23 15:22:18.667975"], ["id", 1]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.1ms)  (0.6ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------- Commontator::ThreadsController: test_0004_must close if authorized and open ---------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.676895"], ["updated_at", "2014-12-23 15:22:18.676895"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.679816"], ["updated_at", "2014-12-23 15:22:18.679816"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:18.682515"], ["updated_at", "2014-12-23 15:22:18.682515"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:22:18.686121"], ["closer_id", 1], ["closer_type", "DummyUser"], ["updated_at", "2014-12-23 15:22:18.687584"], ["id", 1]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", nil], ["updated_at", "2014-12-23 15:22:18.692364"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:22:18.694364"], ["updated_at", "2014-12-23 15:22:18.695484"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------------------------- Commontator::ThreadsController: test_0005_won't reopen unless authorized and closed -----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.701325"], ["updated_at", "2014-12-23 15:22:18.701325"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.703623"], ["updated_at", "2014-12-23 15:22:18.703623"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:18.705546"], ["updated_at", "2014-12-23 15:22:18.705546"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:22:18.706482"], ["updated_at", "2014-12-23 15:22:18.707303"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", nil], ["updated_at", "2014-12-23 15:22:18.722159"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::ThreadsController: test_0006_must reopen if authorized and closed ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.728713"], ["updated_at", "2014-12-23 15:22:18.728713"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.730581"], ["updated_at", "2014-12-23 15:22:18.730581"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:18.732487"], ["updated_at", "2014-12-23 15:22:18.732487"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.0ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:22:18.733405"], ["updated_at", "2014-12-23 15:22:18.734156"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", nil], ["updated_at", "2014-12-23 15:22:18.738541"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.3ms)  (0.1ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:22:18.744162"], ["updated_at", "2014-12-23 15:22:18.745489"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.0ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", nil], ["updated_at", "2014-12-23 15:22:18.748631"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0001_won't subscribe unless authorized ---------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.753581"], ["updated_at", "2014-12-23 15:22:18.753581"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.755275"], ["updated_at", "2014-12-23 15:22:18.755275"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:18.757029"], ["updated_at", "2014-12-23 15:22:18.757029"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:22:18.766972"], ["updated_at", "2014-12-23 15:22:18.766972"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0002_must subscribe if authorized ----------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.775028"], ["updated_at", "2014-12-23 15:22:18.775028"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.778222"], ["updated_at", "2014-12-23 15:22:18.778222"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:18.781297"], ["updated_at", "2014-12-23 15:22:18.781297"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:22:18.787889"], ["updated_at", "2014-12-23 15:22:18.787889"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 7ms (ActiveRecord: 0.4ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:22:18.796000"], ["updated_at", "2014-12-23 15:22:18.796000"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:22:18.803678"], ["updated_at", "2014-12-23 15:22:18.803678"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.6ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0003_won't unsubscribe unless authorized -----------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.810218"], ["updated_at", "2014-12-23 15:22:18.810218"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.813287"], ["updated_at", "2014-12-23 15:22:18.813287"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:18.816314"], ["updated_at", "2014-12-23 15:22:18.816314"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:22:18.821027"], ["updated_at", "2014-12-23 15:22:18.821027"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::SubscriptionsController: test_0004_must unsubscribe if authorized ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.832769"], ["updated_at", "2014-12-23 15:22:18.832769"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.834484"], ["updated_at", "2014-12-23 15:22:18.834484"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:18.836412"], ["updated_at", "2014-12-23 15:22:18.836412"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:22:18.839154"], ["updated_at", "2014-12-23 15:22:18.839154"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:22:18.848575"], ["updated_at", "2014-12-23 15:22:18.848575"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:22:18.856361"], ["updated_at", "2014-12-23 15:22:18.856361"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 3]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.6ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------------- Commontator::CommentsController: test_0001_won't get new unless authorized --------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.869212"], ["updated_at", "2014-12-23 15:22:18.869212"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.872926"], ["updated_at", "2014-12-23 15:22:18.872926"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:18.875473"], ["updated_at", "2014-12-23 15:22:18.875473"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:18.884508"], ["updated_at", "2014-12-23 15:22:18.884508"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------- Commontator::CommentsController: test_0002_must get new if authorized ---------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.894447"], ["updated_at", "2014-12-23 15:22:18.894447"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.896907"], ["updated_at", "2014-12-23 15:22:18.896907"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:18.899145"], ["updated_at", "2014-12-23 15:22:18.899145"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:18.902339"], ["updated_at", "2014-12-23 15:22:18.902339"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0003_won't create unless authorized -------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.920969"], ["updated_at", "2014-12-23 15:22:18.920969"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.923999"], ["updated_at", "2014-12-23 15:22:18.923999"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:18.926917"], ["updated_at", "2014-12-23 15:22:18.926917"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:18.930253"], ["updated_at", "2014-12-23 15:22:18.930253"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:22:18.934403"], ["updated_at", "2014-12-23 15:22:18.935299"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0004_must create if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.939676"], ["updated_at", "2014-12-23 15:22:18.939676"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.941900"], ["updated_at", "2014-12-23 15:22:18.941900"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:18.944795"], ["updated_at", "2014-12-23 15:22:18.944795"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:18.948207"], ["updated_at", "2014-12-23 15:22:18.948207"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:22:18.954311"], ["updated_at", "2014-12-23 15:22:18.954311"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 14ms (ActiveRecord: 0.5ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Another thing"}} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Another thing' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Another thing"], ["created_at", "2014-12-23 15:22:18.968701"], ["updated_at", "2014-12-23 15:22:18.968701"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"And this too"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'And this too' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "And this too"], ["created_at", "2014-12-23 15:22:18.975178"], ["updated_at", "2014-12-23 15:22:18.975178"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.3ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0005_won't create if double posting -------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.982694"], ["updated_at", "2014-12-23 15:22:18.982694"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:18.985632"], ["updated_at", "2014-12-23 15:22:18.985632"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:18.989285"], ["updated_at", "2014-12-23 15:22:18.989285"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:18.992337"], ["updated_at", "2014-12-23 15:22:18.992337"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:22:19.003323"], ["updated_at", "2014-12-23 15:22:19.003323"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.2ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------- Commontator::CommentsController: test_0006_won't edit unless authorized -----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.014576"], ["updated_at", "2014-12-23 15:22:19.014576"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.016552"], ["updated_at", "2014-12-23 15:22:19.016552"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:19.018922"], ["updated_at", "2014-12-23 15:22:19.018922"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:19.021514"], ["updated_at", "2014-12-23 15:22:19.021514"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.3ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 5ms (ActiveRecord: 0.5ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.030113"], ["updated_at", "2014-12-23 15:22:19.030113"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:22:19.034390"], ["updated_at", "2014-12-23 15:22:19.034390"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------ Commontator::CommentsController: test_0007_must edit if authorized ------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.039562"], ["updated_at", "2014-12-23 15:22:19.039562"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.041128"], ["updated_at", "2014-12-23 15:22:19.041128"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:19.043231"], ["updated_at", "2014-12-23 15:22:19.043231"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:19.045687"], ["updated_at", "2014-12-23 15:22:19.045687"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.3ms)  (0.6ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0008_won't update unless authorized -------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.067187"], ["updated_at", "2014-12-23 15:22:19.067187"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.071012"], ["updated_at", "2014-12-23 15:22:19.071012"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:19.074299"], ["updated_at", "2014-12-23 15:22:19.074299"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:19.077388"], ["updated_at", "2014-12-23 15:22:19.077388"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.083684"], ["updated_at", "2014-12-23 15:22:19.083684"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:22:19.088649"], ["updated_at", "2014-12-23 15:22:19.088649"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.5ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0009_must update if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.096159"], ["updated_at", "2014-12-23 15:22:19.096159"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.098677"], ["updated_at", "2014-12-23 15:22:19.098677"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:19.101316"], ["updated_at", "2014-12-23 15:22:19.101316"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:19.104686"], ["updated_at", "2014-12-23 15:22:19.104686"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["body", "Something else"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:22:19.112076"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 8ms (ActiveRecord: 0.5ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.3ms)  (0.6ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------------- Commontator::CommentsController: test_0010_won't delete unless authorized and not deleted -----------------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.131949"], ["updated_at", "2014-12-23 15:22:19.131949"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.135002"], ["updated_at", "2014-12-23 15:22:19.135002"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:19.137796"], ["updated_at", "2014-12-23 15:22:19.137796"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:19.141021"], ["updated_at", "2014-12-23 15:22:19.141021"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-12-23 15:22:19.147164') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:22:19.147164"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:22:19.148987"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.3ms)  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:22:19.158358"], ["updated_at", "2014-12-23 15:22:19.158358"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["updated_at", "2014-12-23 15:22:19.160551"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.6ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------------------ Commontator::CommentsController: test_0011_must delete if authorized and not deleted ------------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.167793"], ["updated_at", "2014-12-23 15:22:19.167793"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.170540"], ["updated_at", "2014-12-23 15:22:19.170540"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:19.173218"], ["updated_at", "2014-12-23 15:22:19.173218"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:19.176382"], ["updated_at", "2014-12-23 15:22:19.176382"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-12-23 15:22:19.181718') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:22:19.181718"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:22:19.183307"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 8ms (ActiveRecord: 0.5ms)  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.188735"], ["updated_at", "2014-12-23 15:22:19.188735"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:22:19.191425"], ["updated_at", "2014-12-23 15:22:19.191425"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["updated_at", "2014-12-23 15:22:19.221472"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-12-23 15:22:19.224199') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:22:19.224199"], ["editor_id", 2], ["updated_at", "2014-12-23 15:22:19.225918"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["editor_id", 1], ["updated_at", "2014-12-23 15:22:19.230712"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-12-23 15:22:19.232959') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:22:19.232959"], ["editor_id", 2], ["updated_at", "2014-12-23 15:22:19.234370"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.3ms)  (0.6ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------------------- Commontator::CommentsController: test_0012_won't undelete unless authorized and deleted ---------------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.241092"], ["updated_at", "2014-12-23 15:22:19.241092"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.244037"], ["updated_at", "2014-12-23 15:22:19.244037"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:19.246813"], ["updated_at", "2014-12-23 15:22:19.246813"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:19.249886"], ["updated_at", "2014-12-23 15:22:19.249886"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-12-23 15:22:19.251056') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:22:19.251056"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:22:19.252519"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.3ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["updated_at", "2014-12-23 15:22:19.260483"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.267990"], ["updated_at", "2014-12-23 15:22:19.267990"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-12-23 15:22:19.268836') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:22:19.268836"], ["editor_id", 2], ["updated_at", "2014-12-23 15:22:19.270134"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:22:19.274771"], ["updated_at", "2014-12-23 15:22:19.274771"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["editor_id", 1], ["updated_at", "2014-12-23 15:22:19.278213"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-12-23 15:22:19.279058') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:22:19.279058"], ["updated_at", "2014-12-23 15:22:19.280262"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.5ms) rollback transaction  (0.3ms) begin transaction ---------------------------------------------------------------------------------- Commontator::CommentsController: test_0013_must undelete if authorized and deleted ----------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.288630"], ["updated_at", "2014-12-23 15:22:19.288630"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.291561"], ["updated_at", "2014-12-23 15:22:19.291561"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:19.294250"], ["updated_at", "2014-12-23 15:22:19.294250"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:19.297371"], ["updated_at", "2014-12-23 15:22:19.297371"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-12-23 15:22:19.298495') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:22:19.298495"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:22:19.299860"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["updated_at", "2014-12-23 15:22:19.305952"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 7ms (ActiveRecord: 0.4ms)  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.311209"], ["updated_at", "2014-12-23 15:22:19.311209"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:22:19.313374"], ["updated_at", "2014-12-23 15:22:19.313374"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-12-23 15:22:19.314337') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:22:19.314337"], ["updated_at", "2014-12-23 15:22:19.315471"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["editor_id", 2], ["updated_at", "2014-12-23 15:22:19.319172"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.3ms)  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-12-23 15:22:19.324045') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:22:19.324045"], ["editor_id", 1], ["updated_at", "2014-12-23 15:22:19.325894"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["editor_id", 2], ["updated_at", "2014-12-23 15:22:19.330253"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.3ms)  (0.7ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0014_won't upvote unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.337387"], ["updated_at", "2014-12-23 15:22:19.337387"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.339688"], ["updated_at", "2014-12-23 15:22:19.339688"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:19.341588"], ["updated_at", "2014-12-23 15:22:19.341588"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:19.343902"], ["updated_at", "2014-12-23 15:22:19.343902"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.353848"], ["updated_at", "2014-12-23 15:22:19.353848"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.6ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0015_must upvote if authorized --------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.361346"], ["updated_at", "2014-12-23 15:22:19.361346"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.364080"], ["updated_at", "2014-12-23 15:22:19.364080"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:19.367149"], ["updated_at", "2014-12-23 15:22:19.367149"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:19.370353"], ["updated_at", "2014-12-23 15:22:19.370353"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.371950"], ["updated_at", "2014-12-23 15:22:19.371950"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("votable_id", "votable_type", "voter_id", "voter_type", "vote_flag", "vote_weight", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"], ["vote_flag", "t"], ["vote_weight", 1], ["created_at", "2014-12-23 15:22:19.382747"], ["updated_at", "2014-12-23 15:22:19.382747"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 14ms (ActiveRecord: 0.7ms)  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 7ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "votes" SET "vote_flag" = ?, "updated_at" = ? WHERE "votes"."id" = ? [["vote_flag", "f"], ["updated_at", "2014-12-23 15:22:19.401824"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "votes" SET "vote_flag" = ?, "updated_at" = ? WHERE "votes"."id" = ? [["vote_flag", "t"], ["updated_at", "2014-12-23 15:22:19.409002"], ["id", 1]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 9ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.6ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------- Commontator::CommentsController: test_0016_won't downvote unless authorized ---------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.419361"], ["updated_at", "2014-12-23 15:22:19.419361"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.423254"], ["updated_at", "2014-12-23 15:22:19.423254"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:19.426069"], ["updated_at", "2014-12-23 15:22:19.426069"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:19.429249"], ["updated_at", "2014-12-23 15:22:19.429249"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.437902"], ["updated_at", "2014-12-23 15:22:19.437902"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.6ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------------- Commontator::CommentsController: test_0017_must downvote if authorized ----------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.445739"], ["updated_at", "2014-12-23 15:22:19.445739"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.448701"], ["updated_at", "2014-12-23 15:22:19.448701"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:19.451630"], ["updated_at", "2014-12-23 15:22:19.451630"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:19.455454"], ["updated_at", "2014-12-23 15:22:19.455454"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.457639"], ["updated_at", "2014-12-23 15:22:19.457639"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("votable_id", "votable_type", "voter_id", "voter_type", "vote_flag", "vote_weight", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"], ["vote_flag", "f"], ["vote_weight", 1], ["created_at", "2014-12-23 15:22:19.464782"], ["updated_at", "2014-12-23 15:22:19.464782"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 9ms (ActiveRecord: 0.6ms)  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 7ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "vote_flag" = ?, "updated_at" = ? WHERE "votes"."id" = ? [["vote_flag", "t"], ["updated_at", "2014-12-23 15:22:19.490179"], ["id", 1]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "vote_flag" = ?, "updated_at" = ? WHERE "votes"."id" = ? [["vote_flag", "f"], ["updated_at", "2014-12-23 15:22:19.497329"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 8ms (ActiveRecord: 0.5ms)  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0018_won't unvote unless authorized -------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.507736"], ["updated_at", "2014-12-23 15:22:19.507736"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.510674"], ["updated_at", "2014-12-23 15:22:19.510674"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:19.513389"], ["updated_at", "2014-12-23 15:22:19.513389"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:19.516545"], ["updated_at", "2014-12-23 15:22:19.516545"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 1], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("votable_id", "votable_type", "voter_id", "voter_type", "vote_flag", "vote_weight", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 1], ["voter_type", "DummyUser"], ["vote_flag", "t"], ["vote_weight", 1], ["created_at", "2014-12-23 15:22:19.519724"], ["updated_at", "2014-12-23 15:22:19.519724"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.529478"], ["updated_at", "2014-12-23 15:22:19.529478"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0019_must unvote if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.535781"], ["updated_at", "2014-12-23 15:22:19.535781"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.537484"], ["updated_at", "2014-12-23 15:22:19.537484"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:19.539279"], ["updated_at", "2014-12-23 15:22:19.539279"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:19.541918"], ["updated_at", "2014-12-23 15:22:19.541918"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.543281"], ["updated_at", "2014-12-23 15:22:19.543281"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("votable_id", "votable_type", "voter_id", "voter_type", "vote_flag", "vote_weight", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"], ["vote_flag", "t"], ["vote_weight", 1], ["created_at", "2014-12-23 15:22:19.546119"], ["updated_at", "2014-12-23 15:22:19.546119"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 8ms (ActiveRecord: 0.7ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.1ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("votable_id", "votable_type", "voter_id", "voter_type", "vote_flag", "vote_weight", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"], ["vote_flag", "f"], ["vote_weight", 1], ["created_at", "2014-12-23 15:22:19.568633"], ["updated_at", "2014-12-23 15:22:19.568633"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 7ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.6ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------------ Commontator::CommentsController: test_0020_won't send mail if recipients empty ------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.583845"], ["updated_at", "2014-12-23 15:22:19.583845"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.586890"], ["updated_at", "2014-12-23 15:22:19.586890"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:19.589758"], ["updated_at", "2014-12-23 15:22:19.589758"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:19.594106"], ["updated_at", "2014-12-23 15:22:19.594106"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.595613"], ["updated_at", "2014-12-23 15:22:19.595613"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:22:19.600213"], ["updated_at", "2014-12-23 15:22:19.600213"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.3ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------------- Commontator::CommentsController: test_0021_must send mail if recipients not empty ---------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.606507"], ["updated_at", "2014-12-23 15:22:19.606507"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.609247"], ["updated_at", "2014-12-23 15:22:19.609247"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:19.611994"], ["updated_at", "2014-12-23 15:22:19.611994"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:19.615103"], ["updated_at", "2014-12-23 15:22:19.615103"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.616511"], ["updated_at", "2014-12-23 15:22:19.616511"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.0ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:22:19.619254"], ["updated_at", "2014-12-23 15:22:19.619254"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:22:19.623798"], ["updated_at", "2014-12-23 15:22:19.623798"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.4ms)  (0.6ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------------- Commontator::Comment: test_0001_must be votable if acts_as_votable is installed -------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.631556"], ["updated_at", "2014-12-23 15:22:19.631556"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.634469"], ["updated_at", "2014-12-23 15:22:19.634469"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:19.637272"], ["updated_at", "2014-12-23 15:22:19.637272"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::Comment: test_0002_must know if it has been modified -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.640662"], ["updated_at", "2014-12-23 15:22:19.640662"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.643158"], ["updated_at", "2014-12-23 15:22:19.643158"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:19.645296"], ["updated_at", "2014-12-23 15:22:19.645296"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:19.647753"], ["updated_at", "2014-12-23 15:22:19.647753"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["body", "Something else"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:22:19.649894"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.5ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------- Commontator::Comment: test_0003_must know if it has been deleted ----------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.652996"], ["updated_at", "2014-12-23 15:22:19.652996"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.655726"], ["updated_at", "2014-12-23 15:22:19.655726"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:19.658288"], ["updated_at", "2014-12-23 15:22:19.658288"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-12-23 15:22:19.660242') LIMIT 1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.661977"], ["updated_at", "2014-12-23 15:22:19.661977"]] SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "deleted_at", "editor_type", "editor_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["deleted_at", "2014-12-23 15:22:19.660242"], ["editor_type", "DummyUser"], ["editor_id", 2], ["created_at", "2014-12-23 15:22:19.662938"], ["updated_at", "2014-12-23 15:22:19.662938"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["updated_at", "2014-12-23 15:22:19.665566"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------- Commontator::Comment: test_0004_must make proper timestamps -----------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.667853"], ["updated_at", "2014-12-23 15:22:19.667853"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.669502"], ["updated_at", "2014-12-23 15:22:19.669502"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:19.671215"], ["updated_at", "2014-12-23 15:22:19.671215"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:19.673695"], ["updated_at", "2014-12-23 15:22:19.673695"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.675576"], ["updated_at", "2014-12-23 15:22:19.675576"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["body", "Something else"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:22:19.677604"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------ Commontator::SubscriptionsMailer: test_0001_must create deliverable mail ------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.840148"], ["updated_at", "2014-12-23 15:22:19.840148"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.842198"], ["updated_at", "2014-12-23 15:22:19.842198"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:19.844076"], ["updated_at", "2014-12-23 15:22:19.844076"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.845144"], ["updated_at", "2014-12-23 15:22:19.845144"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:22:19.847600"], ["updated_at", "2014-12-23 15:22:19.847600"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:22:19.849858"], ["updated_at", "2014-12-23 15:22:19.849858"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:19.852043"], ["updated_at", "2014-12-23 15:22:19.852043"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/comments/_body.html.erb (10.6ms) Rendered /Users/dante/Desktop/commontator/app/views/commontator/subscriptions_mailer/comment_created.html.erb (13.9ms) Commontator::SubscriptionsMailer#comment_created: processed outbound mail in 25.0ms Sent mail to Undisclosed Recipients (14.0ms) Date: Tue, 23 Dec 2014 09:22:19 -0600 From: no-reply@dummy.com To: Undisclosed Recipients Message-ID: <549988abd8870_41c3fd630c65bc4538eb@Dantes-MacBook-Pro.local.mail> Subject: Dummy User #1 posted a comment on DummyModel #1 Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit

Dummy User #1 commented on DummyModel #1:

Something

Click here to view all comments on DummyModel #1.

 (0.6ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::ApplicationHelper: test_0001_must print javascript proc --------------------------------------------------------------------  (0.0ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------- Commontator::Subscription: test_0001_must count unread comments ---------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.906265"], ["updated_at", "2014-12-23 15:22:19.906265"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.908894"], ["updated_at", "2014-12-23 15:22:19.908894"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:19.911333"], ["updated_at", "2014-12-23 15:22:19.911333"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("thread_id", "subscriber_id", "subscriber_type", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["thread_id", 1], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["created_at", "2014-12-23 15:22:19.913751"], ["updated_at", "2014-12-23 15:22:19.913751"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:22:19.913751') [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:19.917324"], ["updated_at", "2014-12-23 15:22:19.917324"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:22:19.913751') [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:22:19.922624"], ["updated_at", "2014-12-23 15:22:19.922624"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:22:19.913751') [["thread_id", 1]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-12-23 15:22:19.926937' WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:22:19.926937') [["thread_id", 1]]  (0.5ms) rollback transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.932008"], ["updated_at", "2014-12-23 15:22:19.932008"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.0ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:22:19.933791"], ["updated_at", "2014-12-23 15:22:19.933791"]]  (0.6ms) commit transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::SharedHelper: test_0001_must show commontator thread -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.939104"], ["updated_at", "2014-12-23 15:22:19.939104"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:22:19.940972"], ["updated_at", "2014-12-23 15:22:19.940972"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 2]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/shared/_thread.html.erb (13.7ms)  (0.3ms) rollback transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.961962"], ["updated_at", "2014-12-23 15:22:19.961962"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.967333"], ["updated_at", "2014-12-23 15:22:19.967333"]]  (0.6ms) commit transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.970337"], ["updated_at", "2014-12-23 15:22:19.970337"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:22:19.972574"], ["updated_at", "2014-12-23 15:22:19.972574"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["created_at", "2014-12-23 15:22:19.977347"], ["updated_at", "2014-12-23 15:22:19.977347"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.979601"], ["updated_at", "2014-12-23 15:22:19.979601"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 3], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 3) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 3], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["created_at", "2014-12-23 15:22:19.983537"], ["updated_at", "2014-12-23 15:22:19.983537"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 2]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 3]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.988356"], ["updated_at", "2014-12-23 15:22:19.988356"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.990570"], ["updated_at", "2014-12-23 15:22:19.990570"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 3 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 3], ["created_at", "2014-12-23 15:22:19.992277"], ["updated_at", "2014-12-23 15:22:19.992277"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 4], ["subscriber_type", "DummyUser"], ["thread_id", 3]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 3 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 4) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 4], ["subscriber_type", "DummyUser"], ["thread_id", 3], ["created_at", "2014-12-23 15:22:19.995790"], ["updated_at", "2014-12-23 15:22:19.995790"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:19.997430"], ["updated_at", "2014-12-23 15:22:19.997430"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 5], ["subscriber_type", "DummyUser"], ["thread_id", 3]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 3 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 5) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 5], ["subscriber_type", "DummyUser"], ["thread_id", 3], ["created_at", "2014-12-23 15:22:20.000695"], ["updated_at", "2014-12-23 15:22:20.000695"]]  (0.8ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 4], ["subscriber_type", "DummyUser"], ["thread_id", 3]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 3]] DummyUser Load (0.2ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 4]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 5], ["subscriber_type", "DummyUser"], ["thread_id", 3]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 3]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:20.006223"], ["updated_at", "2014-12-23 15:22:20.006223"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:20.008615"], ["updated_at", "2014-12-23 15:22:20.008615"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 4]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 4 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 4], ["created_at", "2014-12-23 15:22:20.010249"], ["updated_at", "2014-12-23 15:22:20.010249"]]  (0.7ms) commit transaction  (0.0ms) begin transaction DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", nil]] SQL (0.1ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["commontable_id", nil], ["updated_at", "2014-12-23 15:22:20.012317"], ["id", 4]]  (0.7ms) commit transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 4]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:20.014301"], ["updated_at", "2014-12-23 15:22:20.014301"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:20.016353"], ["updated_at", "2014-12-23 15:22:20.016353"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Exists (0.0ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 5 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 5], ["created_at", "2014-12-23 15:22:20.017862"], ["updated_at", "2014-12-23 15:22:20.017862"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 7 AND "commontator_comments"."thread_id" = 5 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 5], ["creator_id", 7], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:20.020917"], ["updated_at", "2014-12-23 15:22:20.020917"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 7 AND "commontator_comments"."thread_id" = 5 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 5], ["creator_id", 7], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:22:20.023979"], ["updated_at", "2014-12-23 15:22:20.023979"]]  (0.7ms) commit transaction Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 5]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY created_at ASC [["thread_id", 5]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:20.027418"], ["updated_at", "2014-12-23 15:22:20.027418"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:20.029638"], ["updated_at", "2014-12-23 15:22:20.029638"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 6 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 6], ["created_at", "2014-12-23 15:22:20.031329"], ["updated_at", "2014-12-23 15:22:20.031329"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 8], ["subscriber_type", "DummyUser"], ["thread_id", 6]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 6 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 8) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 8], ["subscriber_type", "DummyUser"], ["thread_id", 6], ["created_at", "2014-12-23 15:22:20.034786"], ["updated_at", "2014-12-23 15:22:20.034786"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 8], ["subscriber_type", "DummyUser"], ["thread_id", 6]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 6]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 6]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:22:20.034786') [["thread_id", 6]]  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 8 AND "commontator_comments"."thread_id" = 6 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 6], ["creator_id", 8], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:20.039757"], ["updated_at", "2014-12-23 15:22:20.039757"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 6]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 6]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:22:20.034786') [["thread_id", 6]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 8], ["subscriber_type", "DummyUser"], ["thread_id", 6]]  (0.0ms) begin transaction SQL (0.1ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-12-23 15:22:20.043737' WHERE "commontator_subscriptions"."id" = ? [["id", 5]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 6]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 6]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:22:20.043737') [["thread_id", 6]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:20.046966"], ["updated_at", "2014-12-23 15:22:20.046966"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:20.049161"], ["updated_at", "2014-12-23 15:22:20.049161"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 7]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 7 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 7], ["created_at", "2014-12-23 15:22:20.050919"], ["updated_at", "2014-12-23 15:22:20.050919"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:20.052800"], ["updated_at", "2014-12-23 15:22:20.052800"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:20.055371"], ["updated_at", "2014-12-23 15:22:20.055371"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 8]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 8 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 8], ["created_at", "2014-12-23 15:22:20.057302"], ["updated_at", "2014-12-23 15:22:20.057302"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 10 AND "commontator_comments"."thread_id" = 8 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 8], ["creator_id", 10], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:22:20.060539"], ["updated_at", "2014-12-23 15:22:20.060539"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 8 AND "commontator_threads"."id" != 8 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:22:20.062199"], ["closer_id", 10], ["closer_type", "DummyUser"], ["updated_at", "2014-12-23 15:22:20.063330"], ["id", 8]]  (0.6ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = ? [["thread_id", 8], ["id", 4]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 8]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 8], ["commontable_type", "DummyModel"]]  (0.0ms) begin transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 8]] SQL (0.2ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "commontable_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["commontable_id", nil], ["commontable_type", nil], ["updated_at", "2014-12-23 15:22:20.068531"], ["id", 8]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 8 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 8], ["commontable_type", "DummyModel"], ["created_at", "2014-12-23 15:22:20.069949"], ["updated_at", "2014-12-23 15:22:20.069949"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 8]]  (0.6ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = ? [["thread_id", 8], ["id", 4]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 8]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 8], ["commontable_type", "DummyModel"]] Commontator::Comment Exists (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = ? [["thread_id", 9], ["id", 4]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:20.073890"], ["updated_at", "2014-12-23 15:22:20.073890"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:20.076101"], ["updated_at", "2014-12-23 15:22:20.076101"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 9], ["created_at", "2014-12-23 15:22:20.077702"], ["updated_at", "2014-12-23 15:22:20.077702"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:22:20.079256"], ["closer_id", 11], ["closer_type", "DummyUser"], ["updated_at", "2014-12-23 15:22:20.080247"], ["id", 10]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.2ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."id" != 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.2ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", nil], ["updated_at", "2014-12-23 15:22:20.083149"], ["id", 10]]  (0.7ms) commit transaction  (1.8ms) CREATE TABLE "commontator_comments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "creator_type" varchar, "creator_id" integer, "editor_type" varchar, "editor_id" integer, "thread_id" integer NOT NULL, "body" text NOT NULL, "deleted_at" datetime, "cached_votes_up" integer DEFAULT 0, "cached_votes_down" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime)   (0.1ms) select sqlite_version(*)  (1.0ms) CREATE INDEX "index_commontator_comments_on_cached_votes_down" ON "commontator_comments" ("cached_votes_down")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'  (0.9ms) CREATE INDEX "index_commontator_comments_on_cached_votes_up" ON "commontator_comments" ("cached_votes_up")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_comments_on_c_id_and_c_type_and_t_id" ON "commontator_comments" ("creator_id", "creator_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_comments_on_thread_id_and_created_at" ON "commontator_comments" ("thread_id", "created_at")  (0.8ms) CREATE TABLE "commontator_subscriptions" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "subscriber_type" varchar NOT NULL, "subscriber_id" integer NOT NULL, "thread_id" integer NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE UNIQUE INDEX "index_commontator_subscriptions_on_s_id_and_s_type_and_t_id" ON "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index'   (0.7ms) CREATE INDEX "index_commontator_subscriptions_on_thread_id" ON "commontator_subscriptions" ("thread_id")  (0.8ms) CREATE TABLE "commontator_threads" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "commontable_type" varchar, "commontable_id" integer, "closed_at" datetime, "closer_type" varchar, "closer_id" integer, "created_at" datetime, "updated_at" datetime)   (0.7ms) CREATE UNIQUE INDEX "index_commontator_threads_on_c_id_and_c_type" ON "commontator_threads" ("commontable_id", "commontable_type")  (0.8ms) CREATE TABLE "dummy_models" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE TABLE "dummy_users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)  (0.8ms) CREATE TABLE "votes" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "votable_id" integer, "votable_type" varchar, "voter_id" integer, "voter_type" varchar, "vote_flag" boolean, "vote_scope" varchar, "vote_weight" integer, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE INDEX "index_votes_on_votable_id_and_votable_type_and_vote_scope" ON "votes" ("votable_id", "votable_type", "vote_scope")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index'   (0.8ms) CREATE INDEX "index_votes_on_voter_id_and_voter_type_and_vote_scope" ON "votes" ("voter_id", "voter_type", "vote_scope")  (0.6ms) CREATE TABLE "schema_migrations" ("version" varchar NOT NULL)   (0.6ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.1ms) SELECT version FROM "schema_migrations"  (0.6ms) INSERT INTO "schema_migrations" (version) VALUES ('3')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('1')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('2')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.1ms) begin transaction ---------------------------------------------------------------------- Commontator::ThreadsController: test_0001_won't show unless authorized ----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:22:59.983728"], ["updated_at", "2014-12-23 15:22:59.983728"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (1.0ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.000499"], ["updated_at", "2014-12-23 15:23:00.000499"]] DummyModel Load (0.2ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:23:00.013794"], ["updated_at", "2014-12-23 15:23:00.013794"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.1ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------- Commontator::ThreadsController: test_0002_must show if authorized -----------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.024404"], ["updated_at", "2014-12-23 15:23:00.024404"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.027303"], ["updated_at", "2014-12-23 15:23:00.027303"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:23:00.030110"], ["updated_at", "2014-12-23 15:23:00.030110"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 1], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Redirected to http://test.host/dummy_models/1 Completed 302 Found in 10ms (ActiveRecord: 0.4ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 1], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Redirected to http://test.host/dummy_models/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 1], ["commontable_type", "DummyModel"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Redirected to http://test.host/dummy_models/1 Completed 302 Found in 4ms (ActiveRecord: 0.2ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------------------- Commontator::ThreadsController: test_0003_won't close unless authorized and open --------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.058226"], ["updated_at", "2014-12-23 15:23:00.058226"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.061091"], ["updated_at", "2014-12-23 15:23:00.061091"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:23:00.063785"], ["updated_at", "2014-12-23 15:23:00.063785"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:23:00.069983"], ["updated_at", "2014-12-23 15:23:00.071326"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.1ms)  (0.6ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------- Commontator::ThreadsController: test_0004_must close if authorized and open ---------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.079013"], ["updated_at", "2014-12-23 15:23:00.079013"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.082074"], ["updated_at", "2014-12-23 15:23:00.082074"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:23:00.084978"], ["updated_at", "2014-12-23 15:23:00.084978"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:23:00.088603"], ["closer_id", 1], ["closer_type", "DummyUser"], ["updated_at", "2014-12-23 15:23:00.090081"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", nil], ["updated_at", "2014-12-23 15:23:00.096011"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:23:00.098696"], ["updated_at", "2014-12-23 15:23:00.100040"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.2ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------------------------- Commontator::ThreadsController: test_0005_won't reopen unless authorized and closed -----------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.106225"], ["updated_at", "2014-12-23 15:23:00.106225"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.109162"], ["updated_at", "2014-12-23 15:23:00.109162"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:23:00.111825"], ["updated_at", "2014-12-23 15:23:00.111825"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:23:00.113059"], ["updated_at", "2014-12-23 15:23:00.114192"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", nil], ["updated_at", "2014-12-23 15:23:00.121610"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 10ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------------ Commontator::ThreadsController: test_0006_must reopen if authorized and closed ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.137078"], ["updated_at", "2014-12-23 15:23:00.137078"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.139765"], ["updated_at", "2014-12-23 15:23:00.139765"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:23:00.142233"], ["updated_at", "2014-12-23 15:23:00.142233"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:23:00.143329"], ["updated_at", "2014-12-23 15:23:00.144241"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", nil], ["updated_at", "2014-12-23 15:23:00.148884"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.3ms)  (0.1ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:23:00.154783"], ["updated_at", "2014-12-23 15:23:00.156132"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", nil], ["updated_at", "2014-12-23 15:23:00.159767"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.3ms)  (0.6ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------ Commontator::SubscriptionsMailer: test_0001_must create deliverable mail ------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.301616"], ["updated_at", "2014-12-23 15:23:00.301616"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.303645"], ["updated_at", "2014-12-23 15:23:00.303645"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:23:00.305480"], ["updated_at", "2014-12-23 15:23:00.305480"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.306683"], ["updated_at", "2014-12-23 15:23:00.306683"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:23:00.312062"], ["updated_at", "2014-12-23 15:23:00.312062"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:23:00.314511"], ["updated_at", "2014-12-23 15:23:00.314511"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:00.326003"], ["updated_at", "2014-12-23 15:23:00.326003"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/comments/_body.html.erb (1.1ms) Rendered /Users/dante/Desktop/commontator/app/views/commontator/subscriptions_mailer/comment_created.html.erb (4.3ms) Commontator::SubscriptionsMailer#comment_created: processed outbound mail in 23.2ms Sent mail to Undisclosed Recipients (2.6ms) Date: Tue, 23 Dec 2014 09:23:00 -0600 From: no-reply@dummy.com To: Undisclosed Recipients Message-ID: <549988d457062_4463fdfedc65bbc8377d@Dantes-MacBook-Pro.local.mail> Subject: Dummy User #1 posted a comment on DummyModel #1 Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit

Dummy User #1 commented on DummyModel #1:

Something

Click here to view all comments on DummyModel #1.

 (1.0ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::ApplicationHelper: test_0001_must print javascript proc --------------------------------------------------------------------  (0.0ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------- Commontator::Subscription: test_0001_must count unread comments ---------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.369034"], ["updated_at", "2014-12-23 15:23:00.369034"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.371143"], ["updated_at", "2014-12-23 15:23:00.371143"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:23:00.373231"], ["updated_at", "2014-12-23 15:23:00.373231"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("thread_id", "subscriber_id", "subscriber_type", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["thread_id", 1], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["created_at", "2014-12-23 15:23:00.375486"], ["updated_at", "2014-12-23 15:23:00.375486"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:23:00.375486') [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:00.379632"], ["updated_at", "2014-12-23 15:23:00.379632"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:23:00.375486') [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:23:00.384471"], ["updated_at", "2014-12-23 15:23:00.384471"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:23:00.375486') [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-12-23 15:23:00.387187' WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:23:00.387187') [["thread_id", 1]]  (0.5ms) rollback transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.392306"], ["updated_at", "2014-12-23 15:23:00.392306"]]  (0.7ms) commit transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.395892"], ["updated_at", "2014-12-23 15:23:00.395892"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:23:00.398437"], ["updated_at", "2014-12-23 15:23:00.398437"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:23:00.402878"], ["updated_at", "2014-12-23 15:23:00.402878"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.404644"], ["updated_at", "2014-12-23 15:23:00.404644"]]  (1.0ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:23:00.408336"], ["updated_at", "2014-12-23 15:23:00.408336"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.412992"], ["updated_at", "2014-12-23 15:23:00.412992"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.415186"], ["updated_at", "2014-12-23 15:23:00.415186"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:23:00.417204"], ["updated_at", "2014-12-23 15:23:00.417204"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 3 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 3], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:00.421091"], ["updated_at", "2014-12-23 15:23:00.421091"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:23:00.422719"], ["closer_id", 3], ["closer_type", "DummyUser"], ["updated_at", "2014-12-23 15:23:00.423802"], ["id", 2]]  (0.7ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = ? [["thread_id", 2], ["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 2], ["commontable_type", "DummyModel"]]  (0.0ms) begin transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1  [["id", 2]] SQL (0.1ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "commontable_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["commontable_id", nil], ["commontable_type", nil], ["updated_at", "2014-12-23 15:23:00.429376"], ["id", 2]] Commontator::Thread Exists (0.0ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 2], ["commontable_type", "DummyModel"], ["created_at", "2014-12-23 15:23:00.430810"], ["updated_at", "2014-12-23 15:23:00.430810"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 2]]  (0.6ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = ? [["thread_id", 2], ["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 2], ["commontable_type", "DummyModel"]] Commontator::Comment Exists (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = ? [["thread_id", 3], ["id", 1]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.435179"], ["updated_at", "2014-12-23 15:23:00.435179"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.438659"], ["updated_at", "2014-12-23 15:23:00.438659"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 3 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 3], ["created_at", "2014-12-23 15:23:00.440360"], ["updated_at", "2014-12-23 15:23:00.440360"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 4 AND "commontator_comments"."thread_id" = 4 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 4], ["creator_id", 4], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:00.443341"], ["updated_at", "2014-12-23 15:23:00.443341"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 4 AND "commontator_comments"."thread_id" = 4 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 4], ["creator_id", 4], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:23:00.446302"], ["updated_at", "2014-12-23 15:23:00.446302"]]  (0.6ms) commit transaction Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 4]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY created_at ASC [["thread_id", 4]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.449336"], ["updated_at", "2014-12-23 15:23:00.449336"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.451476"], ["updated_at", "2014-12-23 15:23:00.451476"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 4]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 4 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 4], ["created_at", "2014-12-23 15:23:00.453078"], ["updated_at", "2014-12-23 15:23:00.453078"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 4 AND "commontator_threads"."id" != 5 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:23:00.454570"], ["closer_id", 5], ["closer_type", "DummyUser"], ["updated_at", "2014-12-23 15:23:00.455505"], ["id", 5]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 4 AND "commontator_threads"."id" != 5 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", nil], ["updated_at", "2014-12-23 15:23:00.457708"], ["id", 5]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.459409"], ["updated_at", "2014-12-23 15:23:00.459409"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.461508"], ["updated_at", "2014-12-23 15:23:00.461508"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Exists (0.0ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 5 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 5], ["created_at", "2014-12-23 15:23:00.463064"], ["updated_at", "2014-12-23 15:23:00.463064"]]  (0.7ms) commit transaction  (0.1ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.464962"], ["updated_at", "2014-12-23 15:23:00.464962"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.467092"], ["updated_at", "2014-12-23 15:23:00.467092"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 6 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 6], ["created_at", "2014-12-23 15:23:00.468632"], ["updated_at", "2014-12-23 15:23:00.468632"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 7], ["subscriber_type", "DummyUser"], ["thread_id", 7]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 7 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 7) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 7], ["subscriber_type", "DummyUser"], ["thread_id", 7], ["created_at", "2014-12-23 15:23:00.471923"], ["updated_at", "2014-12-23 15:23:00.471923"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 7], ["subscriber_type", "DummyUser"], ["thread_id", 7]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 7]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 6]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:23:00.471923') [["thread_id", 7]]  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 7 AND "commontator_comments"."thread_id" = 7 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 7], ["creator_id", 7], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:00.476686"], ["updated_at", "2014-12-23 15:23:00.476686"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 7]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 6]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:23:00.471923') [["thread_id", 7]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 7], ["subscriber_type", "DummyUser"], ["thread_id", 7]]  (0.0ms) begin transaction SQL (0.2ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-12-23 15:23:00.480641' WHERE "commontator_subscriptions"."id" = ? [["id", 3]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 7]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 6]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:23:00.480641') [["thread_id", 7]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.484115"], ["updated_at", "2014-12-23 15:23:00.484115"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.486302"], ["updated_at", "2014-12-23 15:23:00.486302"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 7]] Commontator::Thread Exists (0.0ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 7 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 7], ["created_at", "2014-12-23 15:23:00.487906"], ["updated_at", "2014-12-23 15:23:00.487906"]]  (0.6ms) commit transaction  (0.0ms) begin transaction DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", nil]] SQL (0.1ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["commontable_id", nil], ["updated_at", "2014-12-23 15:23:00.489903"], ["id", 8]]  (0.6ms) commit transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 8]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.491841"], ["updated_at", "2014-12-23 15:23:00.491841"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.494031"], ["updated_at", "2014-12-23 15:23:00.494031"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 8]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 8 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 8], ["created_at", "2014-12-23 15:23:00.495622"], ["updated_at", "2014-12-23 15:23:00.495622"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 9], ["subscriber_type", "DummyUser"], ["thread_id", 9]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 9 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 9) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 9], ["subscriber_type", "DummyUser"], ["thread_id", 9], ["created_at", "2014-12-23 15:23:00.498962"], ["updated_at", "2014-12-23 15:23:00.498962"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.500637"], ["updated_at", "2014-12-23 15:23:00.500637"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 10], ["subscriber_type", "DummyUser"], ["thread_id", 9]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 9 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 10) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 10], ["subscriber_type", "DummyUser"], ["thread_id", 9], ["created_at", "2014-12-23 15:23:00.503805"], ["updated_at", "2014-12-23 15:23:00.503805"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 9]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.507483"], ["updated_at", "2014-12-23 15:23:00.507483"]]  (0.6ms) commit transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0001_won't subscribe unless authorized ---------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.510221"], ["updated_at", "2014-12-23 15:23:00.510221"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.511765"], ["updated_at", "2014-12-23 15:23:00.511765"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 9], ["created_at", "2014-12-23 15:23:00.513460"], ["updated_at", "2014-12-23 15:23:00.513460"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]] Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["created_at", "2014-12-23 15:23:00.520118"], ["updated_at", "2014-12-23 15:23:00.520118"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0002_must subscribe if authorized ----------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.527388"], ["updated_at", "2014-12-23 15:23:00.527388"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.530396"], ["updated_at", "2014-12-23 15:23:00.530396"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 9], ["created_at", "2014-12-23 15:23:00.533118"], ["updated_at", "2014-12-23 15:23:00.533118"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["created_at", "2014-12-23 15:23:00.538019"], ["updated_at", "2014-12-23 15:23:00.538019"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 5ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 6]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.0ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["created_at", "2014-12-23 15:23:00.544945"], ["updated_at", "2014-12-23 15:23:00.544945"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 7]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["created_at", "2014-12-23 15:23:00.551499"], ["updated_at", "2014-12-23 15:23:00.551499"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]]  (0.6ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0003_won't unsubscribe unless authorized -----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.557230"], ["updated_at", "2014-12-23 15:23:00.557230"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.559310"], ["updated_at", "2014-12-23 15:23:00.559310"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 9], ["created_at", "2014-12-23 15:23:00.562151"], ["updated_at", "2014-12-23 15:23:00.562151"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["created_at", "2014-12-23 15:23:00.566127"], ["updated_at", "2014-12-23 15:23:00.566127"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]] Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 6]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]] Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------------ Commontator::SubscriptionsController: test_0004_must unsubscribe if authorized ------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.578519"], ["updated_at", "2014-12-23 15:23:00.578519"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.581348"], ["updated_at", "2014-12-23 15:23:00.581348"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 9], ["created_at", "2014-12-23 15:23:00.584009"], ["updated_at", "2014-12-23 15:23:00.584009"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["created_at", "2014-12-23 15:23:00.587500"], ["updated_at", "2014-12-23 15:23:00.587500"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 6]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 4ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["created_at", "2014-12-23 15:23:00.596604"], ["updated_at", "2014-12-23 15:23:00.596604"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 7]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 10 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10], ["created_at", "2014-12-23 15:23:00.604402"], ["updated_at", "2014-12-23 15:23:00.604402"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"10"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 8]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/10 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 10]]  (0.5ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------- Commontator::Comment: test_0001_must be votable if acts_as_votable is installed -------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.613984"], ["updated_at", "2014-12-23 15:23:00.613984"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.616444"], ["updated_at", "2014-12-23 15:23:00.616444"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 9], ["created_at", "2014-12-23 15:23:00.619180"], ["updated_at", "2014-12-23 15:23:00.619180"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::Comment: test_0002_must know if it has been modified -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.624876"], ["updated_at", "2014-12-23 15:23:00.624876"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.626670"], ["updated_at", "2014-12-23 15:23:00.626670"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 9], ["created_at", "2014-12-23 15:23:00.628636"], ["updated_at", "2014-12-23 15:23:00.628636"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 10], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:00.631021"], ["updated_at", "2014-12-23 15:23:00.631021"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["body", "Something else"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:23:00.633106"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.5ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------- Commontator::Comment: test_0003_must know if it has been deleted ----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.636075"], ["updated_at", "2014-12-23 15:23:00.636075"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.638863"], ["updated_at", "2014-12-23 15:23:00.638863"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 9], ["created_at", "2014-12-23 15:23:00.641478"], ["updated_at", "2014-12-23 15:23:00.641478"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" = '2014-12-23 15:23:00.643389') LIMIT 1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.645099"], ["updated_at", "2014-12-23 15:23:00.645099"]] SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "deleted_at", "editor_type", "editor_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["thread_id", 10], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["deleted_at", "2014-12-23 15:23:00.643389"], ["editor_type", "DummyUser"], ["editor_id", 13], ["created_at", "2014-12-23 15:23:00.646044"], ["updated_at", "2014-12-23 15:23:00.646044"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["updated_at", "2014-12-23 15:23:00.648582"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.5ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------- Commontator::Comment: test_0004_must make proper timestamps -----------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.651544"], ["updated_at", "2014-12-23 15:23:00.651544"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.654286"], ["updated_at", "2014-12-23 15:23:00.654286"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 9], ["created_at", "2014-12-23 15:23:00.656918"], ["updated_at", "2014-12-23 15:23:00.656918"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 10], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:00.660058"], ["updated_at", "2014-12-23 15:23:00.660058"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.662171"], ["updated_at", "2014-12-23 15:23:00.662171"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 10 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["body", "Something else"], ["editor_id", 13], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:23:00.664354"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::SharedHelper: test_0001_must show commontator thread -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.670987"], ["updated_at", "2014-12-23 15:23:00.670987"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 9], ["created_at", "2014-12-23 15:23:00.672862"], ["updated_at", "2014-12-23 15:23:00.672862"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 10]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/shared/_thread.html.erb (11.5ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.691309"], ["updated_at", "2014-12-23 15:23:00.691309"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 9], ["created_at", "2014-12-23 15:23:00.693226"], ["updated_at", "2014-12-23 15:23:00.693226"]]  (0.9ms) commit transaction  (0.0ms) begin transaction -------------------------------------------------------------------------- Commontator::CommentsController: test_0001_won't get new unless authorized --------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.697876"], ["updated_at", "2014-12-23 15:23:00.697876"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.699555"], ["updated_at", "2014-12-23 15:23:00.699555"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:23:00.701324"], ["updated_at", "2014-12-23 15:23:00.701324"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:00.703741"], ["updated_at", "2014-12-23 15:23:00.703741"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"11"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------- Commontator::CommentsController: test_0002_must get new if authorized ---------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.710486"], ["updated_at", "2014-12-23 15:23:00.710486"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.713218"], ["updated_at", "2014-12-23 15:23:00.713218"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:23:00.715821"], ["updated_at", "2014-12-23 15:23:00.715821"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:00.718932"], ["updated_at", "2014-12-23 15:23:00.718932"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"11"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0003_won't create unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.737210"], ["updated_at", "2014-12-23 15:23:00.737210"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.739829"], ["updated_at", "2014-12-23 15:23:00.739829"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:23:00.742311"], ["updated_at", "2014-12-23 15:23:00.742311"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:00.745093"], ["updated_at", "2014-12-23 15:23:00.745093"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."id" != 11 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:23:00.748802"], ["updated_at", "2014-12-23 15:23:00.749676"], ["id", 11]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0004_must create if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.753755"], ["updated_at", "2014-12-23 15:23:00.753755"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.755374"], ["updated_at", "2014-12-23 15:23:00.755374"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:23:00.757059"], ["updated_at", "2014-12-23 15:23:00.757059"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:00.759339"], ["updated_at", "2014-12-23 15:23:00.759339"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:23:00.763474"], ["updated_at", "2014-12-23 15:23:00.763474"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 5ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Another thing"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Another thing' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Another thing"], ["created_at", "2014-12-23 15:23:00.771327"], ["updated_at", "2014-12-23 15:23:00.771327"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 5ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"And this too"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'And this too' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "And this too"], ["created_at", "2014-12-23 15:23:00.778712"], ["updated_at", "2014-12-23 15:23:00.778712"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 5ms (ActiveRecord: 0.3ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0005_won't create if double posting -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.785413"], ["updated_at", "2014-12-23 15:23:00.785413"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.787195"], ["updated_at", "2014-12-23 15:23:00.787195"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:23:00.789056"], ["updated_at", "2014-12-23 15:23:00.789056"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:00.791373"], ["updated_at", "2014-12-23 15:23:00.791373"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 5ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:23:00.803017"], ["updated_at", "2014-12-23 15:23:00.803017"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 5ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 4ms (ActiveRecord: 0.2ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------- Commontator::CommentsController: test_0006_won't edit unless authorized -----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.815056"], ["updated_at", "2014-12-23 15:23:00.815056"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.816731"], ["updated_at", "2014-12-23 15:23:00.816731"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:23:00.818462"], ["updated_at", "2014-12-23 15:23:00.818462"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:00.820823"], ["updated_at", "2014-12-23 15:23:00.820823"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.826792"], ["updated_at", "2014-12-23 15:23:00.826792"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:23:00.830898"], ["updated_at", "2014-12-23 15:23:00.830898"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms)  (0.6ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------ Commontator::CommentsController: test_0007_must edit if authorized ------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.837243"], ["updated_at", "2014-12-23 15:23:00.837243"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.839942"], ["updated_at", "2014-12-23 15:23:00.839942"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:23:00.842594"], ["updated_at", "2014-12-23 15:23:00.842594"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:00.845676"], ["updated_at", "2014-12-23 15:23:00.845676"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 4ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0008_won't update unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.864285"], ["updated_at", "2014-12-23 15:23:00.864285"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.866908"], ["updated_at", "2014-12-23 15:23:00.866908"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:23:00.869710"], ["updated_at", "2014-12-23 15:23:00.869710"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:00.872823"], ["updated_at", "2014-12-23 15:23:00.872823"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.878915"], ["updated_at", "2014-12-23 15:23:00.878915"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:23:00.883301"], ["updated_at", "2014-12-23 15:23:00.883301"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.6ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0009_must update if authorized --------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.889734"], ["updated_at", "2014-12-23 15:23:00.889734"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.892446"], ["updated_at", "2014-12-23 15:23:00.892446"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:23:00.895075"], ["updated_at", "2014-12-23 15:23:00.895075"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:00.898156"], ["updated_at", "2014-12-23 15:23:00.898156"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["body", "Something else"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:23:00.904283"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 6ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 5ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"5", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 5ms (ActiveRecord: 0.4ms)  (0.6ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------------- Commontator::CommentsController: test_0010_won't delete unless authorized and not deleted -----------------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.923559"], ["updated_at", "2014-12-23 15:23:00.923559"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.926445"], ["updated_at", "2014-12-23 15:23:00.926445"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:23:00.929183"], ["updated_at", "2014-12-23 15:23:00.929183"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:00.932260"], ["updated_at", "2014-12-23 15:23:00.932260"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-12-23 15:23:00.937946') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:23:00.937946"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:23:00.939603"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 4ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:23:00.947547"], ["updated_at", "2014-12-23 15:23:00.947547"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["updated_at", "2014-12-23 15:23:00.949609"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.6ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------------------ Commontator::CommentsController: test_0011_must delete if authorized and not deleted ------------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.956190"], ["updated_at", "2014-12-23 15:23:00.956190"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.958909"], ["updated_at", "2014-12-23 15:23:00.958909"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:23:00.961539"], ["updated_at", "2014-12-23 15:23:00.961539"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:00.964625"], ["updated_at", "2014-12-23 15:23:00.964625"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-12-23 15:23:00.969194') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:23:00.969194"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:23:00.970515"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 6ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.974299"], ["updated_at", "2014-12-23 15:23:00.974299"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:23:00.976536"], ["updated_at", "2014-12-23 15:23:00.976536"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["updated_at", "2014-12-23 15:23:00.978474"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-12-23 15:23:00.980678') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:23:00.980678"], ["editor_id", 13], ["updated_at", "2014-12-23 15:23:00.981939"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 5ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["editor_id", 12], ["updated_at", "2014-12-23 15:23:00.986421"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-12-23 15:23:00.988739') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:23:00.988739"], ["editor_id", 13], ["updated_at", "2014-12-23 15:23:00.990134"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 5ms (ActiveRecord: 0.3ms)  (0.6ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------------------- Commontator::CommentsController: test_0012_won't undelete unless authorized and deleted ---------------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.996293"], ["updated_at", "2014-12-23 15:23:00.996293"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:00.999441"], ["updated_at", "2014-12-23 15:23:00.999441"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:23:01.002275"], ["updated_at", "2014-12-23 15:23:01.002275"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:01.005522"], ["updated_at", "2014-12-23 15:23:01.005522"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-12-23 15:23:01.006702') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:23:01.006702"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:23:01.008187"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["updated_at", "2014-12-23 15:23:01.015943"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 4ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.022163"], ["updated_at", "2014-12-23 15:23:01.022163"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-12-23 15:23:01.023061') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:23:01.023061"], ["editor_id", 13], ["updated_at", "2014-12-23 15:23:01.024397"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 13]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:23:01.029009"], ["updated_at", "2014-12-23 15:23:01.029009"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["editor_id", 12], ["updated_at", "2014-12-23 15:23:01.031598"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-12-23 15:23:01.032357') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:23:01.032357"], ["updated_at", "2014-12-23 15:23:01.033339"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.3ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.5ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------------------------- Commontator::CommentsController: test_0013_must undelete if authorized and deleted ----------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.040326"], ["updated_at", "2014-12-23 15:23:01.040326"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.042905"], ["updated_at", "2014-12-23 15:23:01.042905"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:23:01.045441"], ["updated_at", "2014-12-23 15:23:01.045441"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:01.048400"], ["updated_at", "2014-12-23 15:23:01.048400"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-12-23 15:23:01.049596') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:23:01.049596"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:23:01.051054"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 11]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["updated_at", "2014-12-23 15:23:01.057014"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 6ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.060756"], ["updated_at", "2014-12-23 15:23:01.060756"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:23:01.062920"], ["updated_at", "2014-12-23 15:23:01.062920"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-12-23 15:23:01.063807') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:23:01.063807"], ["updated_at", "2014-12-23 15:23:01.064968"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["editor_id", 13], ["updated_at", "2014-12-23 15:23:01.068495"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 4ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-12-23 15:23:01.071468') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:23:01.071468"], ["editor_id", 12], ["updated_at", "2014-12-23 15:23:01.072649"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["editor_id", 13], ["updated_at", "2014-12-23 15:23:01.076348"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 5ms (ActiveRecord: 0.3ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0014_won't upvote unless authorized -------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.082375"], ["updated_at", "2014-12-23 15:23:01.082375"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.085378"], ["updated_at", "2014-12-23 15:23:01.085378"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:23:01.088246"], ["updated_at", "2014-12-23 15:23:01.088246"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:01.091366"], ["updated_at", "2014-12-23 15:23:01.091366"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.100670"], ["updated_at", "2014-12-23 15:23:01.100670"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.6ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0015_must upvote if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.107279"], ["updated_at", "2014-12-23 15:23:01.107279"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.109330"], ["updated_at", "2014-12-23 15:23:01.109330"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:23:01.111994"], ["updated_at", "2014-12-23 15:23:01.111994"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:01.115168"], ["updated_at", "2014-12-23 15:23:01.115168"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.116648"], ["updated_at", "2014-12-23 15:23:01.116648"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "votes" ("votable_id", "votable_type", "voter_id", "voter_type", "vote_flag", "vote_weight", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"], ["vote_flag", "t"], ["vote_weight", 1], ["created_at", "2014-12-23 15:23:01.133804"], ["updated_at", "2014-12-23 15:23:01.133804"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 5]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 22ms (ActiveRecord: 0.8ms)  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 5]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 18ms (ActiveRecord: 0.5ms)  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "votes" SET "vote_flag" = ?, "updated_at" = ? WHERE "votes"."id" = ? [["vote_flag", "f"], ["updated_at", "2014-12-23 15:23:01.168790"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = ? [["id", 5]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "vote_flag" = ?, "updated_at" = ? WHERE "votes"."id" = ? [["vote_flag", "t"], ["updated_at", "2014-12-23 15:23:01.175567"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 5]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 8ms (ActiveRecord: 0.4ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.6ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------- Commontator::CommentsController: test_0016_won't downvote unless authorized ---------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.184942"], ["updated_at", "2014-12-23 15:23:01.184942"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.188005"], ["updated_at", "2014-12-23 15:23:01.188005"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:23:01.190881"], ["updated_at", "2014-12-23 15:23:01.190881"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:01.194066"], ["updated_at", "2014-12-23 15:23:01.194066"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.202209"], ["updated_at", "2014-12-23 15:23:01.202209"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------- Commontator::CommentsController: test_0017_must downvote if authorized ----------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.209455"], ["updated_at", "2014-12-23 15:23:01.209455"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.212247"], ["updated_at", "2014-12-23 15:23:01.212247"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:23:01.214991"], ["updated_at", "2014-12-23 15:23:01.214991"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:01.218149"], ["updated_at", "2014-12-23 15:23:01.218149"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.219759"], ["updated_at", "2014-12-23 15:23:01.219759"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("votable_id", "votable_type", "voter_id", "voter_type", "vote_flag", "vote_weight", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"], ["vote_flag", "f"], ["vote_weight", 1], ["created_at", "2014-12-23 15:23:01.225403"], ["updated_at", "2014-12-23 15:23:01.225403"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = ? [["id", 5]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 8ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = ? [["id", 5]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 6ms (ActiveRecord: 0.4ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "vote_flag" = ?, "updated_at" = ? WHERE "votes"."id" = ? [["vote_flag", "t"], ["updated_at", "2014-12-23 15:23:01.242881"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 5]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "vote_flag" = ?, "updated_at" = ? WHERE "votes"."id" = ? [["vote_flag", "f"], ["updated_at", "2014-12-23 15:23:01.249444"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = ? [["id", 5]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 7ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.6ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0018_won't unvote unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.257598"], ["updated_at", "2014-12-23 15:23:01.257598"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.259542"], ["updated_at", "2014-12-23 15:23:01.259542"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:23:01.262341"], ["updated_at", "2014-12-23 15:23:01.262341"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:01.266031"], ["updated_at", "2014-12-23 15:23:01.266031"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 12], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("votable_id", "votable_type", "voter_id", "voter_type", "vote_flag", "vote_weight", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 12], ["voter_type", "DummyUser"], ["vote_flag", "t"], ["vote_weight", 1], ["created_at", "2014-12-23 15:23:01.269744"], ["updated_at", "2014-12-23 15:23:01.269744"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 5]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.279910"], ["updated_at", "2014-12-23 15:23:01.279910"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0019_must unvote if authorized --------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.287161"], ["updated_at", "2014-12-23 15:23:01.287161"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.289918"], ["updated_at", "2014-12-23 15:23:01.289918"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:23:01.292693"], ["updated_at", "2014-12-23 15:23:01.292693"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:01.295846"], ["updated_at", "2014-12-23 15:23:01.295846"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.297349"], ["updated_at", "2014-12-23 15:23:01.297349"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("votable_id", "votable_type", "voter_id", "voter_type", "vote_flag", "vote_weight", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"], ["vote_flag", "t"], ["vote_weight", 1], ["created_at", "2014-12-23 15:23:01.300148"], ["updated_at", "2014-12-23 15:23:01.300148"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 5]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 5]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 8ms (ActiveRecord: 0.6ms)  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 4ms (ActiveRecord: 0.1ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("votable_id", "votable_type", "voter_id", "voter_type", "vote_flag", "vote_weight", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"], ["vote_flag", "f"], ["vote_weight", 1], ["created_at", "2014-12-23 15:23:01.324296"], ["updated_at", "2014-12-23 15:23:01.324296"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 5]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = ? [["id", 5]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"5"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"], ["voter_id", 13], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 5]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 5], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 7ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 5], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::CommentsController: test_0020_won't send mail if recipients empty ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.339745"], ["updated_at", "2014-12-23 15:23:01.339745"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.341661"], ["updated_at", "2014-12-23 15:23:01.341661"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:23:01.344436"], ["updated_at", "2014-12-23 15:23:01.344436"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:01.348135"], ["updated_at", "2014-12-23 15:23:01.348135"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.349785"], ["updated_at", "2014-12-23 15:23:01.349785"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:23:01.354702"], ["updated_at", "2014-12-23 15:23:01.354702"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 11]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 6ms (ActiveRecord: 0.4ms)  (0.6ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------- Commontator::CommentsController: test_0021_must send mail if recipients not empty ---------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.361112"], ["updated_at", "2014-12-23 15:23:01.361112"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.364079"], ["updated_at", "2014-12-23 15:23:01.364079"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:23:01.366905"], ["updated_at", "2014-12-23 15:23:01.366905"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:23:01.370103"], ["updated_at", "2014-12-23 15:23:01.370103"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:23:01.371580"], ["updated_at", "2014-12-23 15:23:01.371580"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 13], ["subscriber_type", "DummyUser"], ["thread_id", 11]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 11 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 13) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 13], ["subscriber_type", "DummyUser"], ["thread_id", 11], ["created_at", "2014-12-23 15:23:01.374587"], ["updated_at", "2014-12-23 15:23:01.374587"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"11", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 11]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:23:01.379203"], ["updated_at", "2014-12-23 15:23:01.379203"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 11]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 13]] Redirected to http://test.host/commontator/threads/11 Completed 302 Found in 6ms (ActiveRecord: 0.4ms)  (0.5ms) rollback transaction  (1.4ms) CREATE TABLE "commontator_comments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "creator_type" varchar, "creator_id" integer, "editor_type" varchar, "editor_id" integer, "thread_id" integer NOT NULL, "body" text NOT NULL, "deleted_at" datetime, "cached_votes_up" integer DEFAULT 0, "cached_votes_down" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime)   (0.1ms) select sqlite_version(*)  (0.8ms) CREATE INDEX "index_commontator_comments_on_cached_votes_down" ON "commontator_comments" ("cached_votes_down")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'  (0.7ms) CREATE INDEX "index_commontator_comments_on_cached_votes_up" ON "commontator_comments" ("cached_votes_up")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.7ms) CREATE INDEX "index_commontator_comments_on_c_id_and_c_type_and_t_id" ON "commontator_comments" ("creator_id", "creator_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.7ms) CREATE INDEX "index_commontator_comments_on_thread_id_and_created_at" ON "commontator_comments" ("thread_id", "created_at")  (0.8ms) CREATE TABLE "commontator_subscriptions" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "subscriber_type" varchar NOT NULL, "subscriber_id" integer NOT NULL, "thread_id" integer NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE UNIQUE INDEX "index_commontator_subscriptions_on_s_id_and_s_type_and_t_id" ON "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index'   (0.7ms) CREATE INDEX "index_commontator_subscriptions_on_thread_id" ON "commontator_subscriptions" ("thread_id")  (0.8ms) CREATE TABLE "commontator_threads" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "commontable_type" varchar, "commontable_id" integer, "closed_at" datetime, "closer_type" varchar, "closer_id" integer, "created_at" datetime, "updated_at" datetime)   (0.7ms) CREATE UNIQUE INDEX "index_commontator_threads_on_c_id_and_c_type" ON "commontator_threads" ("commontable_id", "commontable_type")  (0.7ms) CREATE TABLE "dummy_models" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE TABLE "dummy_users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)  (0.8ms) CREATE TABLE "votes" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "votable_id" integer, "votable_type" varchar, "voter_id" integer, "voter_type" varchar, "vote_flag" boolean, "vote_scope" varchar, "vote_weight" integer, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE INDEX "index_votes_on_votable_id_and_votable_type_and_vote_scope" ON "votes" ("votable_id", "votable_type", "vote_scope")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index'   (0.8ms) CREATE INDEX "index_votes_on_voter_id_and_voter_type_and_vote_scope" ON "votes" ("voter_id", "voter_type", "vote_scope")  (0.8ms) CREATE TABLE "schema_migrations" ("version" varchar NOT NULL)   (0.8ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.1ms) SELECT version FROM "schema_migrations"  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('3')  (0.8ms) INSERT INTO "schema_migrations" (version) VALUES ('1')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('2')  (0.8ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.1ms) begin transaction --------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0001_won't subscribe unless authorized ---------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:05.649596"], ["updated_at", "2014-12-23 15:24:05.649596"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.8ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:05.666803"], ["updated_at", "2014-12-23 15:24:05.666803"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:05.676399"], ["updated_at", "2014-12-23 15:24:05.676399"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:24:05.696145"], ["updated_at", "2014-12-23 15:24:05.696145"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.1ms)  (1.0ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0002_must subscribe if authorized ----------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:05.705472"], ["updated_at", "2014-12-23 15:24:05.705472"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:05.708515"], ["updated_at", "2014-12-23 15:24:05.708515"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:05.711295"], ["updated_at", "2014-12-23 15:24:05.711295"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:24:05.718018"], ["updated_at", "2014-12-23 15:24:05.718018"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 7ms (ActiveRecord: 0.5ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:24:05.728378"], ["updated_at", "2014-12-23 15:24:05.728378"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:24:05.735479"], ["updated_at", "2014-12-23 15:24:05.735479"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.6ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0003_won't unsubscribe unless authorized -----------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:05.741534"], ["updated_at", "2014-12-23 15:24:05.741534"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:05.744504"], ["updated_at", "2014-12-23 15:24:05.744504"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:05.747400"], ["updated_at", "2014-12-23 15:24:05.747400"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:24:05.751186"], ["updated_at", "2014-12-23 15:24:05.751186"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.1ms)  (0.6ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------------ Commontator::SubscriptionsController: test_0004_must unsubscribe if authorized ------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:05.764981"], ["updated_at", "2014-12-23 15:24:05.764981"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:05.767911"], ["updated_at", "2014-12-23 15:24:05.767911"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:05.770781"], ["updated_at", "2014-12-23 15:24:05.770781"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:24:05.774743"], ["updated_at", "2014-12-23 15:24:05.774743"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 11ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:24:05.791654"], ["updated_at", "2014-12-23 15:24:05.791654"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:24:05.799343"], ["updated_at", "2014-12-23 15:24:05.799343"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 3]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.6ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::ApplicationHelper: test_0001_must print javascript proc --------------------------------------------------------------------  (0.1ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::SharedHelper: test_0001_must show commontator thread -----------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:05.820745"], ["updated_at", "2014-12-23 15:24:05.820745"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:05.822885"], ["updated_at", "2014-12-23 15:24:05.822885"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 1]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/shared/_thread.html.erb (13.9ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:05.846907"], ["updated_at", "2014-12-23 15:24:05.846907"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:05.849895"], ["updated_at", "2014-12-23 15:24:05.849895"]]  (0.9ms) commit transaction  (0.1ms) begin transaction --------------------------------------------------------------- Commontator::Subscription: test_0001_must count unread comments ---------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:05.854119"], ["updated_at", "2014-12-23 15:24:05.854119"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:05.857199"], ["updated_at", "2014-12-23 15:24:05.857199"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:05.859771"], ["updated_at", "2014-12-23 15:24:05.859771"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("thread_id", "subscriber_id", "subscriber_type", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["thread_id", 2], ["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["created_at", "2014-12-23 15:24:05.862162"], ["updated_at", "2014-12-23 15:24:05.862162"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:24:05.862162') [["thread_id", 2]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:05.871159"], ["updated_at", "2014-12-23 15:24:05.871159"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:24:05.862162') [["thread_id", 2]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:05.875883"], ["updated_at", "2014-12-23 15:24:05.875883"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:24:05.862162') [["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-12-23 15:24:05.878450' WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:24:05.878450') [["thread_id", 2]]  (0.5ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------------- Commontator::CommentsController: test_0001_won't get new unless authorized --------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:05.884728"], ["updated_at", "2014-12-23 15:24:05.884728"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:05.886433"], ["updated_at", "2014-12-23 15:24:05.886433"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:05.888208"], ["updated_at", "2014-12-23 15:24:05.888208"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:05.891781"], ["updated_at", "2014-12-23 15:24:05.891781"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"2"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------- Commontator::CommentsController: test_0002_must get new if authorized ---------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:05.900451"], ["updated_at", "2014-12-23 15:24:05.900451"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:05.902734"], ["updated_at", "2014-12-23 15:24:05.902734"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:05.904900"], ["updated_at", "2014-12-23 15:24:05.904900"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:05.907721"], ["updated_at", "2014-12-23 15:24:05.907721"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 3ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 3ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 4ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0003_won't create unless authorized -------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:05.928866"], ["updated_at", "2014-12-23 15:24:05.928866"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:05.931757"], ["updated_at", "2014-12-23 15:24:05.931757"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:05.934420"], ["updated_at", "2014-12-23 15:24:05.934420"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:05.937510"], ["updated_at", "2014-12-23 15:24:05.937510"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"2", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"2", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:24:05.941480"], ["updated_at", "2014-12-23 15:24:05.942903"], ["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"2", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.6ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0004_must create if authorized --------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:05.948311"], ["updated_at", "2014-12-23 15:24:05.948311"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:05.951093"], ["updated_at", "2014-12-23 15:24:05.951093"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:05.953709"], ["updated_at", "2014-12-23 15:24:05.953709"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:05.956902"], ["updated_at", "2014-12-23 15:24:05.956902"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"2", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:05.961731"], ["updated_at", "2014-12-23 15:24:05.961731"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 2]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 7ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"2", "comment"=>{"body"=>"Another thing"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Another thing' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Another thing"], ["created_at", "2014-12-23 15:24:05.970322"], ["updated_at", "2014-12-23 15:24:05.970322"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 2]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 6ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"2", "comment"=>{"body"=>"And this too"}} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'And this too' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "And this too"], ["created_at", "2014-12-23 15:24:05.978815"], ["updated_at", "2014-12-23 15:24:05.978815"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 2]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 5ms (ActiveRecord: 0.3ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0005_won't create if double posting -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:05.984460"], ["updated_at", "2014-12-23 15:24:05.984460"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:05.986305"], ["updated_at", "2014-12-23 15:24:05.986305"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:05.988100"], ["updated_at", "2014-12-23 15:24:05.988100"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:05.990532"], ["updated_at", "2014-12-23 15:24:05.990532"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"2", "comment"=>{"body"=>"Something"}} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 5ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"2", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:06.001826"], ["updated_at", "2014-12-23 15:24:06.001826"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 2]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 5ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"2", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 4ms (ActiveRecord: 0.2ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------- Commontator::CommentsController: test_0006_won't edit unless authorized -----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.020298"], ["updated_at", "2014-12-23 15:24:06.020298"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.022571"], ["updated_at", "2014-12-23 15:24:06.022571"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:06.024619"], ["updated_at", "2014-12-23 15:24:06.024619"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:06.026978"], ["updated_at", "2014-12-23 15:24:06.026978"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.2ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.2ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 2]] Completed 403 Forbidden in 5ms (ActiveRecord: 0.5ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.035781"], ["updated_at", "2014-12-23 15:24:06.035781"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:06.041167"], ["updated_at", "2014-12-23 15:24:06.041167"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms)  (0.6ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------ Commontator::CommentsController: test_0007_must edit if authorized ------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.047672"], ["updated_at", "2014-12-23 15:24:06.047672"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.050411"], ["updated_at", "2014-12-23 15:24:06.050411"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:06.053052"], ["updated_at", "2014-12-23 15:24:06.053052"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:06.056440"], ["updated_at", "2014-12-23 15:24:06.056440"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 2]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 2]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 2]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (1.0ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0008_won't update unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.076775"], ["updated_at", "2014-12-23 15:24:06.076775"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.079536"], ["updated_at", "2014-12-23 15:24:06.079536"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:06.081965"], ["updated_at", "2014-12-23 15:24:06.081965"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:06.084683"], ["updated_at", "2014-12-23 15:24:06.084683"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.090415"], ["updated_at", "2014-12-23 15:24:06.090415"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:06.095118"], ["updated_at", "2014-12-23 15:24:06.095118"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.5ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0009_must update if authorized --------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.102398"], ["updated_at", "2014-12-23 15:24:06.102398"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.105178"], ["updated_at", "2014-12-23 15:24:06.105178"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:06.109113"], ["updated_at", "2014-12-23 15:24:06.109113"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:06.112285"], ["updated_at", "2014-12-23 15:24:06.112285"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["body", "Something else"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:24:06.118303"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 6ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 5ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.4ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.3ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 6ms (ActiveRecord: 1.0ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------------- Commontator::CommentsController: test_0010_won't delete unless authorized and not deleted -----------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.139034"], ["updated_at", "2014-12-23 15:24:06.139034"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.141081"], ["updated_at", "2014-12-23 15:24:06.141081"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:06.143119"], ["updated_at", "2014-12-23 15:24:06.143119"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:06.145475"], ["updated_at", "2014-12-23 15:24:06.145475"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" = '2014-12-23 15:24:06.151171') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:24:06.151171"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:24:06.152900"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 2]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 5ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:06.162344"], ["updated_at", "2014-12-23 15:24:06.162344"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["updated_at", "2014-12-23 15:24:06.164573"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.6ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------------------ Commontator::CommentsController: test_0011_must delete if authorized and not deleted ------------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.171464"], ["updated_at", "2014-12-23 15:24:06.171464"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.174243"], ["updated_at", "2014-12-23 15:24:06.174243"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:06.177352"], ["updated_at", "2014-12-23 15:24:06.177352"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:06.180719"], ["updated_at", "2014-12-23 15:24:06.180719"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" = '2014-12-23 15:24:06.185428') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:24:06.185428"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:24:06.186811"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 7ms (ActiveRecord: 0.4ms)  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.192192"], ["updated_at", "2014-12-23 15:24:06.192192"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:06.194757"], ["updated_at", "2014-12-23 15:24:06.194757"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["updated_at", "2014-12-23 15:24:06.196788"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" = '2014-12-23 15:24:06.199203') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:24:06.199203"], ["editor_id", 2], ["updated_at", "2014-12-23 15:24:06.200494"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 4ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["editor_id", 1], ["updated_at", "2014-12-23 15:24:06.204674"], ["id", 1]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" = '2014-12-23 15:24:06.206843') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:24:06.206843"], ["editor_id", 2], ["updated_at", "2014-12-23 15:24:06.208170"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 4ms (ActiveRecord: 0.2ms)  (0.6ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------------- Commontator::CommentsController: test_0012_won't undelete unless authorized and deleted ---------------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.214287"], ["updated_at", "2014-12-23 15:24:06.214287"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.217271"], ["updated_at", "2014-12-23 15:24:06.217271"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:06.220439"], ["updated_at", "2014-12-23 15:24:06.220439"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:06.224881"], ["updated_at", "2014-12-23 15:24:06.224881"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" = '2014-12-23 15:24:06.226096') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:24:06.226096"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:24:06.227414"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 2]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["updated_at", "2014-12-23 15:24:06.235224"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 2]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 31ms (ActiveRecord: 0.2ms)  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.268273"], ["updated_at", "2014-12-23 15:24:06.268273"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" = '2014-12-23 15:24:06.269181') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:24:06.269181"], ["editor_id", 2], ["updated_at", "2014-12-23 15:24:06.270620"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:06.275890"], ["updated_at", "2014-12-23 15:24:06.275890"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["editor_id", 1], ["updated_at", "2014-12-23 15:24:06.278419"], ["id", 1]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" = '2014-12-23 15:24:06.279146') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:24:06.279146"], ["updated_at", "2014-12-23 15:24:06.280149"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 2]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.6ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------------------------- Commontator::CommentsController: test_0013_must undelete if authorized and deleted ----------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.287374"], ["updated_at", "2014-12-23 15:24:06.287374"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.290135"], ["updated_at", "2014-12-23 15:24:06.290135"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:06.292853"], ["updated_at", "2014-12-23 15:24:06.292853"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:06.295984"], ["updated_at", "2014-12-23 15:24:06.295984"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" = '2014-12-23 15:24:06.297097') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:24:06.297097"], ["editor_id", 1], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:24:06.298567"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["updated_at", "2014-12-23 15:24:06.304839"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 7ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.308547"], ["updated_at", "2014-12-23 15:24:06.308547"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:06.311023"], ["updated_at", "2014-12-23 15:24:06.311023"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" = '2014-12-23 15:24:06.312269') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:24:06.312269"], ["updated_at", "2014-12-23 15:24:06.313602"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["editor_id", 2], ["updated_at", "2014-12-23 15:24:06.317888"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 5ms (ActiveRecord: 0.3ms)  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" = '2014-12-23 15:24:06.321636') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:24:06.321636"], ["editor_id", 1], ["updated_at", "2014-12-23 15:24:06.323387"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["editor_id", 2], ["updated_at", "2014-12-23 15:24:06.327572"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 5ms (ActiveRecord: 0.2ms)  (0.6ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0014_won't upvote unless authorized -------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.333947"], ["updated_at", "2014-12-23 15:24:06.333947"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.336873"], ["updated_at", "2014-12-23 15:24:06.336873"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:06.339757"], ["updated_at", "2014-12-23 15:24:06.339757"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:06.344036"], ["updated_at", "2014-12-23 15:24:06.344036"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.353763"], ["updated_at", "2014-12-23 15:24:06.353763"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0015_must upvote if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.359792"], ["updated_at", "2014-12-23 15:24:06.359792"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.361452"], ["updated_at", "2014-12-23 15:24:06.361452"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:06.363247"], ["updated_at", "2014-12-23 15:24:06.363247"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:06.365563"], ["updated_at", "2014-12-23 15:24:06.365563"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.366697"], ["updated_at", "2014-12-23 15:24:06.366697"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]]  (0.2ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "votes" ("votable_id", "votable_type", "voter_id", "voter_type", "vote_flag", "vote_weight", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"], ["vote_flag", "t"], ["vote_weight", 1], ["created_at", "2014-12-23 15:24:06.378261"], ["updated_at", "2014-12-23 15:24:06.378261"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 14ms (ActiveRecord: 0.9ms)  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 7ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "votes" SET "vote_flag" = ?, "updated_at" = ? WHERE "votes"."id" = ? [["vote_flag", "f"], ["updated_at", "2014-12-23 15:24:06.396568"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "vote_flag" = ?, "updated_at" = ? WHERE "votes"."id" = ? [["vote_flag", "t"], ["updated_at", "2014-12-23 15:24:06.402974"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 8ms (ActiveRecord: 0.5ms)  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------- Commontator::CommentsController: test_0016_won't downvote unless authorized ---------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.411976"], ["updated_at", "2014-12-23 15:24:06.411976"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.413899"], ["updated_at", "2014-12-23 15:24:06.413899"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:06.416141"], ["updated_at", "2014-12-23 15:24:06.416141"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:06.418585"], ["updated_at", "2014-12-23 15:24:06.418585"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.428005"], ["updated_at", "2014-12-23 15:24:06.428005"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.6ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------- Commontator::CommentsController: test_0017_must downvote if authorized ----------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.435306"], ["updated_at", "2014-12-23 15:24:06.435306"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.438040"], ["updated_at", "2014-12-23 15:24:06.438040"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:06.441199"], ["updated_at", "2014-12-23 15:24:06.441199"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:06.444559"], ["updated_at", "2014-12-23 15:24:06.444559"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.446217"], ["updated_at", "2014-12-23 15:24:06.446217"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("votable_id", "votable_type", "voter_id", "voter_type", "vote_flag", "vote_weight", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"], ["vote_flag", "f"], ["vote_weight", 1], ["created_at", "2014-12-23 15:24:06.452980"], ["updated_at", "2014-12-23 15:24:06.452980"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 10ms (ActiveRecord: 0.6ms)  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 7ms (ActiveRecord: 0.4ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "votes" SET "vote_flag" = ?, "updated_at" = ? WHERE "votes"."id" = ? [["vote_flag", "t"], ["updated_at", "2014-12-23 15:24:06.472082"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "vote_flag" = ?, "updated_at" = ? WHERE "votes"."id" = ? [["vote_flag", "f"], ["updated_at", "2014-12-23 15:24:06.479048"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 8ms (ActiveRecord: 0.5ms)  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.6ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0018_won't unvote unless authorized -------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.490590"], ["updated_at", "2014-12-23 15:24:06.490590"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.493284"], ["updated_at", "2014-12-23 15:24:06.493284"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:06.496212"], ["updated_at", "2014-12-23 15:24:06.496212"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:06.499457"], ["updated_at", "2014-12-23 15:24:06.499457"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 1], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("votable_id", "votable_type", "voter_id", "voter_type", "vote_flag", "vote_weight", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 1], ["voter_type", "DummyUser"], ["vote_flag", "t"], ["vote_weight", 1], ["created_at", "2014-12-23 15:24:06.502641"], ["updated_at", "2014-12-23 15:24:06.502641"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (6.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.518348"], ["updated_at", "2014-12-23 15:24:06.518348"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0019_must unvote if authorized --------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.525586"], ["updated_at", "2014-12-23 15:24:06.525586"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.527540"], ["updated_at", "2014-12-23 15:24:06.527540"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:06.529421"], ["updated_at", "2014-12-23 15:24:06.529421"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:06.531807"], ["updated_at", "2014-12-23 15:24:06.531807"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.532955"], ["updated_at", "2014-12-23 15:24:06.532955"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("votable_id", "votable_type", "voter_id", "voter_type", "vote_flag", "vote_weight", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"], ["vote_flag", "t"], ["vote_weight", 1], ["created_at", "2014-12-23 15:24:06.535931"], ["updated_at", "2014-12-23 15:24:06.535931"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 9ms (ActiveRecord: 0.7ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 3ms (ActiveRecord: 0.1ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("votable_id", "votable_type", "voter_id", "voter_type", "vote_flag", "vote_weight", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"], ["vote_flag", "f"], ["vote_weight", 1], ["created_at", "2014-12-23 15:24:06.558377"], ["updated_at", "2014-12-23 15:24:06.558377"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 8ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.6ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------------ Commontator::CommentsController: test_0020_won't send mail if recipients empty ------------------------------------------------------------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.575258"], ["updated_at", "2014-12-23 15:24:06.575258"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.578457"], ["updated_at", "2014-12-23 15:24:06.578457"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:06.581236"], ["updated_at", "2014-12-23 15:24:06.581236"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:06.584295"], ["updated_at", "2014-12-23 15:24:06.584295"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.585692"], ["updated_at", "2014-12-23 15:24:06.585692"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"2", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:06.590197"], ["updated_at", "2014-12-23 15:24:06.590197"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 2]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 5ms (ActiveRecord: 0.3ms)  (0.6ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------- Commontator::CommentsController: test_0021_must send mail if recipients not empty ---------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.596530"], ["updated_at", "2014-12-23 15:24:06.596530"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.599424"], ["updated_at", "2014-12-23 15:24:06.599424"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:06.602177"], ["updated_at", "2014-12-23 15:24:06.602177"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:06.605965"], ["updated_at", "2014-12-23 15:24:06.605965"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.608168"], ["updated_at", "2014-12-23 15:24:06.608168"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["created_at", "2014-12-23 15:24:06.612483"], ["updated_at", "2014-12-23 15:24:06.612483"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"2", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:06.618139"], ["updated_at", "2014-12-23 15:24:06.618139"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 7ms (ActiveRecord: 0.4ms)  (0.6ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------------- Commontator::ThreadsController: test_0001_won't show unless authorized ----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.627704"], ["updated_at", "2014-12-23 15:24:06.627704"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.630580"], ["updated_at", "2014-12-23 15:24:06.630580"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:06.633140"], ["updated_at", "2014-12-23 15:24:06.633140"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------- Commontator::ThreadsController: test_0002_must show if authorized -----------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.640444"], ["updated_at", "2014-12-23 15:24:06.640444"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.643144"], ["updated_at", "2014-12-23 15:24:06.643144"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:06.645680"], ["updated_at", "2014-12-23 15:24:06.645680"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 2], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 2]] Redirected to http://test.host/dummy_models/2 Completed 302 Found in 6ms (ActiveRecord: 0.2ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 2], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 2]] Redirected to http://test.host/dummy_models/2 Completed 302 Found in 4ms (ActiveRecord: 0.2ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 2], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 2]] Redirected to http://test.host/dummy_models/2 Completed 302 Found in 3ms (ActiveRecord: 0.1ms)  (0.6ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------------------- Commontator::ThreadsController: test_0003_won't close unless authorized and open --------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.666859"], ["updated_at", "2014-12-23 15:24:06.666859"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.669745"], ["updated_at", "2014-12-23 15:24:06.669745"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:06.672418"], ["updated_at", "2014-12-23 15:24:06.672418"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"2"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:24:06.678638"], ["updated_at", "2014-12-23 15:24:06.679692"], ["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 3ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------- Commontator::ThreadsController: test_0004_must close if authorized and open ---------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.686901"], ["updated_at", "2014-12-23 15:24:06.686901"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.689944"], ["updated_at", "2014-12-23 15:24:06.689944"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:06.692770"], ["updated_at", "2014-12-23 15:24:06.692770"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.2ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:24:06.696588"], ["closer_id", 1], ["closer_type", "DummyUser"], ["updated_at", "2014-12-23 15:24:06.698355"], ["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 6ms (ActiveRecord: 0.5ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", nil], ["updated_at", "2014-12-23 15:24:06.704881"], ["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:24:06.707878"], ["updated_at", "2014-12-23 15:24:06.709460"], ["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 5ms (ActiveRecord: 0.3ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------------------------- Commontator::ThreadsController: test_0005_won't reopen unless authorized and closed -----------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.715120"], ["updated_at", "2014-12-23 15:24:06.715120"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.717212"], ["updated_at", "2014-12-23 15:24:06.717212"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:06.719916"], ["updated_at", "2014-12-23 15:24:06.719916"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:24:06.721290"], ["updated_at", "2014-12-23 15:24:06.722317"], ["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"2"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", nil], ["updated_at", "2014-12-23 15:24:06.729340"], ["id", 2]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 3ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------------ Commontator::ThreadsController: test_0006_must reopen if authorized and closed ------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.737060"], ["updated_at", "2014-12-23 15:24:06.737060"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.740066"], ["updated_at", "2014-12-23 15:24:06.740066"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:06.743760"], ["updated_at", "2014-12-23 15:24:06.743760"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:24:06.744938"], ["updated_at", "2014-12-23 15:24:06.745882"], ["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", nil], ["updated_at", "2014-12-23 15:24:06.749874"], ["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 4ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:24:06.753322"], ["updated_at", "2014-12-23 15:24:06.754294"], ["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.0ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", nil], ["updated_at", "2014-12-23 15:24:06.756936"], ["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 4ms (ActiveRecord: 0.2ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.763510"], ["updated_at", "2014-12-23 15:24:06.763510"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.767091"], ["updated_at", "2014-12-23 15:24:06.767091"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:06.769649"], ["updated_at", "2014-12-23 15:24:06.769649"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 1) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["created_at", "2014-12-23 15:24:06.774056"], ["updated_at", "2014-12-23 15:24:06.774056"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 2]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:24:06.774056') [["thread_id", 2]]  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 1 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 1], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:06.779517"], ["updated_at", "2014-12-23 15:24:06.779517"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:24:06.774056') [["thread_id", 2]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 1], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.0ms) begin transaction SQL (0.1ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-12-23 15:24:06.783997' WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:24:06.783997') [["thread_id", 2]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.787486"], ["updated_at", "2014-12-23 15:24:06.787486"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.789761"], ["updated_at", "2014-12-23 15:24:06.789761"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 3 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 3], ["created_at", "2014-12-23 15:24:06.793103"], ["updated_at", "2014-12-23 15:24:06.793103"]]  (0.8ms) commit transaction  (0.0ms) begin transaction DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", nil]] SQL (0.1ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["commontable_id", nil], ["updated_at", "2014-12-23 15:24:06.795612"], ["id", 3]]  (0.7ms) commit transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 3]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.797791"], ["updated_at", "2014-12-23 15:24:06.797791"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.799981"], ["updated_at", "2014-12-23 15:24:06.799981"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 4]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 4 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 4], ["created_at", "2014-12-23 15:24:06.801647"], ["updated_at", "2014-12-23 15:24:06.801647"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 3], ["subscriber_type", "DummyUser"], ["thread_id", 4]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 4 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 3) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 3], ["subscriber_type", "DummyUser"], ["thread_id", 4], ["created_at", "2014-12-23 15:24:06.805275"], ["updated_at", "2014-12-23 15:24:06.805275"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.806906"], ["updated_at", "2014-12-23 15:24:06.806906"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 4], ["subscriber_type", "DummyUser"], ["thread_id", 4]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 4 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 4) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 4], ["subscriber_type", "DummyUser"], ["thread_id", 4], ["created_at", "2014-12-23 15:24:06.810141"], ["updated_at", "2014-12-23 15:24:06.810141"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 3], ["subscriber_type", "DummyUser"], ["thread_id", 4]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 4]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 3]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 4], ["subscriber_type", "DummyUser"], ["thread_id", 4]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 4]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 4]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.819730"], ["updated_at", "2014-12-23 15:24:06.819730"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.822562"], ["updated_at", "2014-12-23 15:24:06.822562"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 5 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 5], ["created_at", "2014-12-23 15:24:06.824998"], ["updated_at", "2014-12-23 15:24:06.824998"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 5 AND "commontator_threads"."id" != 5 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:24:06.826575"], ["closer_id", 5], ["closer_type", "DummyUser"], ["updated_at", "2014-12-23 15:24:06.827531"], ["id", 5]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 5 AND "commontator_threads"."id" != 5 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", nil], ["updated_at", "2014-12-23 15:24:06.829830"], ["id", 5]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.831354"], ["updated_at", "2014-12-23 15:24:06.831354"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.833481"], ["updated_at", "2014-12-23 15:24:06.833481"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 6 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 6], ["created_at", "2014-12-23 15:24:06.835124"], ["updated_at", "2014-12-23 15:24:06.835124"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 6], ["subscriber_type", "DummyUser"], ["thread_id", 6]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 6 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 6) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 6], ["subscriber_type", "DummyUser"], ["thread_id", 6], ["created_at", "2014-12-23 15:24:06.838434"], ["updated_at", "2014-12-23 15:24:06.838434"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.840193"], ["updated_at", "2014-12-23 15:24:06.840193"]]  (0.5ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 7], ["subscriber_type", "DummyUser"], ["thread_id", 6]]  (0.1ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 6 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 7) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 7], ["subscriber_type", "DummyUser"], ["thread_id", 6], ["created_at", "2014-12-23 15:24:06.844871"], ["updated_at", "2014-12-23 15:24:06.844871"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 6]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 6]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 7]]  (0.1ms) begin transaction SQL (0.4ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.849134"], ["updated_at", "2014-12-23 15:24:06.849134"]]  (4.9ms) commit transaction  (0.1ms) begin transaction SQL (0.4ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.856854"], ["updated_at", "2014-12-23 15:24:06.856854"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 7]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 7 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 7], ["created_at", "2014-12-23 15:24:06.859738"], ["updated_at", "2014-12-23 15:24:06.859738"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.862084"], ["updated_at", "2014-12-23 15:24:06.862084"]]  (0.8ms) commit transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.865040"], ["updated_at", "2014-12-23 15:24:06.865040"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 8]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 8 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 8], ["created_at", "2014-12-23 15:24:06.867533"], ["updated_at", "2014-12-23 15:24:06.867533"]]  (0.8ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 9 AND "commontator_comments"."thread_id" = 8 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 8], ["creator_id", 9], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:06.871532"], ["updated_at", "2014-12-23 15:24:06.871532"]]  (1.0ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 9 AND "commontator_comments"."thread_id" = 8 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 8], ["creator_id", 9], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:06.875684"], ["updated_at", "2014-12-23 15:24:06.875684"]]  (0.6ms) commit transaction Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 8]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY created_at ASC [["thread_id", 8]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.879141"], ["updated_at", "2014-12-23 15:24:06.879141"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.881415"], ["updated_at", "2014-12-23 15:24:06.881415"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.0ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 9], ["created_at", "2014-12-23 15:24:06.883071"], ["updated_at", "2014-12-23 15:24:06.883071"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 10 AND "commontator_comments"."thread_id" = 9 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 9], ["creator_id", 10], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:06.886220"], ["updated_at", "2014-12-23 15:24:06.886220"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."id" != 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:24:06.887831"], ["closer_id", 10], ["closer_type", "DummyUser"], ["updated_at", "2014-12-23 15:24:06.888830"], ["id", 9]]  (0.6ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = ? [["thread_id", 9], ["id", 4]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 9], ["commontable_type", "DummyModel"]]  (0.0ms) begin transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1  [["id", 9]] SQL (0.1ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "commontable_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["commontable_id", nil], ["commontable_type", nil], ["updated_at", "2014-12-23 15:24:06.894142"], ["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 9], ["commontable_type", "DummyModel"], ["created_at", "2014-12-23 15:24:06.895525"], ["updated_at", "2014-12-23 15:24:06.895525"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 9]]  (0.7ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = ? [["thread_id", 9], ["id", 4]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 9], ["commontable_type", "DummyModel"]] Commontator::Comment Exists (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = ? [["thread_id", 10], ["id", 4]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:06.900180"], ["updated_at", "2014-12-23 15:24:06.900180"]]  (0.6ms) commit transaction  (0.0ms) begin transaction ------------------------------------------------------------------------ Commontator::SubscriptionsMailer: test_0001_must create deliverable mail ------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:07.031468"], ["updated_at", "2014-12-23 15:24:07.031468"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:07.033385"], ["updated_at", "2014-12-23 15:24:07.033385"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:24:07.035158"], ["updated_at", "2014-12-23 15:24:07.035158"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:07.036225"], ["updated_at", "2014-12-23 15:24:07.036225"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 11]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 11 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 12) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 12], ["subscriber_type", "DummyUser"], ["thread_id", 11], ["created_at", "2014-12-23 15:24:07.038651"], ["updated_at", "2014-12-23 15:24:07.038651"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 13], ["subscriber_type", "DummyUser"], ["thread_id", 11]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 11 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 13) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 13], ["subscriber_type", "DummyUser"], ["thread_id", 11], ["created_at", "2014-12-23 15:24:07.040823"], ["updated_at", "2014-12-23 15:24:07.040823"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:07.042933"], ["updated_at", "2014-12-23 15:24:07.042933"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 11]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 12]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 13]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/comments/_body.html.erb (0.9ms) Rendered /Users/dante/Desktop/commontator/app/views/commontator/subscriptions_mailer/comment_created.html.erb (2.1ms) Commontator::SubscriptionsMailer#comment_created: processed outbound mail in 11.1ms Sent mail to Undisclosed Recipients (2.7ms) Date: Tue, 23 Dec 2014 09:24:07 -0600 From: no-reply@dummy.com To: Undisclosed Recipients Message-ID: <54998917e962_4753fe2d1465bc421233@Dantes-MacBook-Pro.local.mail> Subject: Dummy User #12 posted a comment on DummyModel #10 Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit

Dummy User #12 commented on DummyModel #10:

Something

Click here to view all comments on DummyModel #10.

 (0.5ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------------- Commontator::Comment: test_0001_must be votable if acts_as_votable is installed -------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:07.071048"], ["updated_at", "2014-12-23 15:24:07.071048"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:07.073116"], ["updated_at", "2014-12-23 15:24:07.073116"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:24:07.075033"], ["updated_at", "2014-12-23 15:24:07.075033"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.5ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------- Commontator::Comment: test_0002_must know if it has been modified -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:07.078233"], ["updated_at", "2014-12-23 15:24:07.078233"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:07.081085"], ["updated_at", "2014-12-23 15:24:07.081085"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:24:07.083626"], ["updated_at", "2014-12-23 15:24:07.083626"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:07.086952"], ["updated_at", "2014-12-23 15:24:07.086952"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["body", "Something else"], ["editor_id", 12], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:24:07.089534"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------- Commontator::Comment: test_0003_must know if it has been deleted ----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:07.091954"], ["updated_at", "2014-12-23 15:24:07.091954"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:07.093745"], ["updated_at", "2014-12-23 15:24:07.093745"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:24:07.095978"], ["updated_at", "2014-12-23 15:24:07.095978"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" = '2014-12-23 15:24:07.097497') LIMIT 1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:07.098849"], ["updated_at", "2014-12-23 15:24:07.098849"]] SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "deleted_at", "editor_type", "editor_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["deleted_at", "2014-12-23 15:24:07.097497"], ["editor_type", "DummyUser"], ["editor_id", 13], ["created_at", "2014-12-23 15:24:07.099620"], ["updated_at", "2014-12-23 15:24:07.099620"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["updated_at", "2014-12-23 15:24:07.101918"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.5ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------- Commontator::Comment: test_0004_must make proper timestamps -----------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:07.104821"], ["updated_at", "2014-12-23 15:24:07.104821"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:07.108355"], ["updated_at", "2014-12-23 15:24:07.108355"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 10]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 10 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 10], ["created_at", "2014-12-23 15:24:07.111518"], ["updated_at", "2014-12-23 15:24:07.111518"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 11], ["creator_id", 12], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:07.114672"], ["updated_at", "2014-12-23 15:24:07.114672"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:07.116710"], ["updated_at", "2014-12-23 15:24:07.116710"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 5 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 12 AND "commontator_comments"."thread_id" = 11 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["body", "Something else"], ["editor_id", 13], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:24:07.118721"], ["id", 5]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (1.8ms) CREATE TABLE "commontator_comments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "creator_type" varchar, "creator_id" integer, "editor_type" varchar, "editor_id" integer, "thread_id" integer NOT NULL, "body" text NOT NULL, "deleted_at" datetime, "cached_votes_up" integer DEFAULT 0, "cached_votes_down" integer DEFAULT 0, "created_at" datetime, "updated_at" datetime)   (0.1ms) select sqlite_version(*)  (1.0ms) CREATE INDEX "index_commontator_comments_on_cached_votes_down" ON "commontator_comments" ("cached_votes_down")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'  (0.8ms) CREATE INDEX "index_commontator_comments_on_cached_votes_up" ON "commontator_comments" ("cached_votes_up")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_comments_on_c_id_and_c_type_and_t_id" ON "commontator_comments" ("creator_id", "creator_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_comments_on_thread_id_and_created_at" ON "commontator_comments" ("thread_id", "created_at")  (0.7ms) CREATE TABLE "commontator_subscriptions" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "subscriber_type" varchar NOT NULL, "subscriber_id" integer NOT NULL, "thread_id" integer NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE UNIQUE INDEX "index_commontator_subscriptions_on_s_id_and_s_type_and_t_id" ON "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index'   (0.8ms) CREATE INDEX "index_commontator_subscriptions_on_thread_id" ON "commontator_subscriptions" ("thread_id")  (0.7ms) CREATE TABLE "commontator_threads" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "commontable_type" varchar, "commontable_id" integer, "closed_at" datetime, "closer_type" varchar, "closer_id" integer, "created_at" datetime, "updated_at" datetime)   (0.7ms) CREATE UNIQUE INDEX "index_commontator_threads_on_c_id_and_c_type" ON "commontator_threads" ("commontable_id", "commontable_type")  (0.7ms) CREATE TABLE "dummy_models" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE TABLE "dummy_users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)  (0.8ms) CREATE TABLE "votes" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "votable_id" integer, "votable_type" varchar, "voter_id" integer, "voter_type" varchar, "vote_flag" boolean, "vote_scope" varchar, "vote_weight" integer, "created_at" datetime, "updated_at" datetime)   (0.8ms) CREATE INDEX "index_votes_on_votable_id_and_votable_type_and_vote_scope" ON "votes" ("votable_id", "votable_type", "vote_scope")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index'   (0.8ms) CREATE INDEX "index_votes_on_voter_id_and_voter_type_and_vote_scope" ON "votes" ("voter_id", "voter_type", "vote_scope")  (0.8ms) CREATE TABLE "schema_migrations" ("version" varchar NOT NULL)   (0.7ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.1ms) SELECT version FROM "schema_migrations"  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('3')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('1')  (0.7ms) INSERT INTO "schema_migrations" (version) VALUES ('2')  (0.8ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.1ms) begin transaction ----------------------------------------------------------------- Commontator::SharedHelper: test_0001_must show commontator thread -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.312291"], ["updated_at", "2014-12-23 15:24:47.312291"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:47.321961"], ["updated_at", "2014-12-23 15:24:47.321961"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Rendered /Users/dante/Desktop/commontator/app/views/commontator/shared/_thread.html.erb (3.1ms)  (0.9ms) rollback transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.339360"], ["updated_at", "2014-12-23 15:24:47.339360"]]  (0.7ms) commit transaction  (0.0ms) begin transaction -------------------------------------------------------------------------- Commontator::CommentsController: test_0001_won't get new unless authorized --------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.344308"], ["updated_at", "2014-12-23 15:24:47.344308"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.346480"], ["updated_at", "2014-12-23 15:24:47.346480"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:47.349256"], ["updated_at", "2014-12-23 15:24:47.349256"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:47.357961"], ["updated_at", "2014-12-23 15:24:47.357961"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------- Commontator::CommentsController: test_0002_must get new if authorized ---------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.369346"], ["updated_at", "2014-12-23 15:24:47.369346"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.371967"], ["updated_at", "2014-12-23 15:24:47.371967"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:47.375781"], ["updated_at", "2014-12-23 15:24:47.375781"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:47.379370"], ["updated_at", "2014-12-23 15:24:47.379370"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.1ms) Processing by Commontator::CommentsController#new as HTML Parameters: {"thread_id"=>"1"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.6ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0003_won't create unless authorized -------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.397415"], ["updated_at", "2014-12-23 15:24:47.397415"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.400461"], ["updated_at", "2014-12-23 15:24:47.400461"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:47.403395"], ["updated_at", "2014-12-23 15:24:47.403395"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:47.406775"], ["updated_at", "2014-12-23 15:24:47.406775"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."id" != 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:24:47.410976"], ["updated_at", "2014-12-23 15:24:47.420134"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.6ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0004_must create if authorized --------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.425721"], ["updated_at", "2014-12-23 15:24:47.425721"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.428467"], ["updated_at", "2014-12-23 15:24:47.428467"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:47.431277"], ["updated_at", "2014-12-23 15:24:47.431277"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:47.434491"], ["updated_at", "2014-12-23 15:24:47.434491"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:47.439344"], ["updated_at", "2014-12-23 15:24:47.439344"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 11ms (ActiveRecord: 0.5ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Another thing"}} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Another thing' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Another thing"], ["created_at", "2014-12-23 15:24:47.452454"], ["updated_at", "2014-12-23 15:24:47.452454"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"And this too"}} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'And this too' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "And this too"], ["created_at", "2014-12-23 15:24:47.460992"], ["updated_at", "2014-12-23 15:24:47.460992"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 8ms (ActiveRecord: 0.5ms)  (0.6ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0005_won't create if double posting -------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.469482"], ["updated_at", "2014-12-23 15:24:47.469482"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.472436"], ["updated_at", "2014-12-23 15:24:47.472436"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:47.475173"], ["updated_at", "2014-12-23 15:24:47.475173"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:47.478295"], ["updated_at", "2014-12-23 15:24:47.478295"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:47.489950"], ["updated_at", "2014-12-23 15:24:47.489950"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.3ms) Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.2ms)  (0.6ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------- Commontator::CommentsController: test_0006_won't edit unless authorized -----------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.502730"], ["updated_at", "2014-12-23 15:24:47.502730"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.505782"], ["updated_at", "2014-12-23 15:24:47.505782"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:47.508851"], ["updated_at", "2014-12-23 15:24:47.508851"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:47.512214"], ["updated_at", "2014-12-23 15:24:47.512214"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 4ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.520003"], ["updated_at", "2014-12-23 15:24:47.520003"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:47.524474"], ["updated_at", "2014-12-23 15:24:47.524474"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------ Commontator::CommentsController: test_0007_must edit if authorized ------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.529798"], ["updated_at", "2014-12-23 15:24:47.529798"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.531457"], ["updated_at", "2014-12-23 15:24:47.531457"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:47.533243"], ["updated_at", "2014-12-23 15:24:47.533243"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:47.535564"], ["updated_at", "2014-12-23 15:24:47.535564"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::CommentsController#edit as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.2ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0008_won't update unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.554417"], ["updated_at", "2014-12-23 15:24:47.554417"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.557193"], ["updated_at", "2014-12-23 15:24:47.557193"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:47.559861"], ["updated_at", "2014-12-23 15:24:47.559861"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:47.562746"], ["updated_at", "2014-12-23 15:24:47.562746"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.568823"], ["updated_at", "2014-12-23 15:24:47.568823"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:47.573544"], ["updated_at", "2014-12-23 15:24:47.573544"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.6ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0009_must update if authorized --------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.580186"], ["updated_at", "2014-12-23 15:24:47.580186"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.582904"], ["updated_at", "2014-12-23 15:24:47.582904"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:47.585585"], ["updated_at", "2014-12-23 15:24:47.585585"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:47.588796"], ["updated_at", "2014-12-23 15:24:47.588796"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["body", "Something else"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:24:47.595213"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 7ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.4ms) Processing by Commontator::CommentsController#update as HTML Parameters: {"id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.4ms)  (0.6ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------------------------------- Commontator::CommentsController: test_0010_won't delete unless authorized and not deleted -----------------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.614947"], ["updated_at", "2014-12-23 15:24:47.614947"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.617775"], ["updated_at", "2014-12-23 15:24:47.617775"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:47.620844"], ["updated_at", "2014-12-23 15:24:47.620844"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:47.624195"], ["updated_at", "2014-12-23 15:24:47.624195"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-12-23 15:24:47.630546') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:24:47.630546"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:24:47.632606"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:47.641188"], ["updated_at", "2014-12-23 15:24:47.641188"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["updated_at", "2014-12-23 15:24:47.643760"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.6ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------------ Commontator::CommentsController: test_0011_must delete if authorized and not deleted ------------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.678084"], ["updated_at", "2014-12-23 15:24:47.678084"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.680917"], ["updated_at", "2014-12-23 15:24:47.680917"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:47.683625"], ["updated_at", "2014-12-23 15:24:47.683625"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:47.686770"], ["updated_at", "2014-12-23 15:24:47.686770"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-12-23 15:24:47.691382') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:24:47.691382"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:24:47.692756"], ["id", 1]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.696512"], ["updated_at", "2014-12-23 15:24:47.696512"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:47.698889"], ["updated_at", "2014-12-23 15:24:47.698889"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["updated_at", "2014-12-23 15:24:47.700941"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-12-23 15:24:47.703289') LIMIT 1 SQL (0.1ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:24:47.703289"], ["editor_id", 3], ["updated_at", "2014-12-23 15:24:47.704612"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["editor_id", 2], ["updated_at", "2014-12-23 15:24:47.709015"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#delete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-12-23 15:24:47.711299') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:24:47.711299"], ["editor_id", 3], ["updated_at", "2014-12-23 15:24:47.712804"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.3ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------------------- Commontator::CommentsController: test_0012_won't undelete unless authorized and deleted ---------------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.719332"], ["updated_at", "2014-12-23 15:24:47.719332"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.722264"], ["updated_at", "2014-12-23 15:24:47.722264"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:47.725311"], ["updated_at", "2014-12-23 15:24:47.725311"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:47.728608"], ["updated_at", "2014-12-23 15:24:47.728608"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-12-23 15:24:47.729767') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:24:47.729767"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:24:47.731202"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["updated_at", "2014-12-23 15:24:47.739279"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.745513"], ["updated_at", "2014-12-23 15:24:47.745513"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-12-23 15:24:47.746326') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:24:47.746326"], ["editor_id", 3], ["updated_at", "2014-12-23 15:24:47.747684"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 3]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:47.752370"], ["updated_at", "2014-12-23 15:24:47.752370"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["editor_id", 2], ["updated_at", "2014-12-23 15:24:47.755136"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-12-23 15:24:47.755974') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:24:47.755974"], ["updated_at", "2014-12-23 15:24:47.757224"], ["id", 1]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]] Completed 403 Forbidden in 3ms (ActiveRecord: 0.2ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.5ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------------------- Commontator::CommentsController: test_0013_must undelete if authorized and deleted ----------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.764505"], ["updated_at", "2014-12-23 15:24:47.764505"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.767218"], ["updated_at", "2014-12-23 15:24:47.767218"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:47.769992"], ["updated_at", "2014-12-23 15:24:47.769992"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:47.773270"], ["updated_at", "2014-12-23 15:24:47.773270"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-12-23 15:24:47.774468') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:24:47.774468"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:24:47.775895"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY "commontator_comments"."id" DESC LIMIT 1 [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["updated_at", "2014-12-23 15:24:47.781890"], ["id", 1]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 7ms (ActiveRecord: 0.4ms)  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.787287"], ["updated_at", "2014-12-23 15:24:47.787287"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:47.789743"], ["updated_at", "2014-12-23 15:24:47.789743"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-12-23 15:24:47.790672') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:24:47.790672"], ["updated_at", "2014-12-23 15:24:47.791893"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["editor_id", 3], ["updated_at", "2014-12-23 15:24:47.795707"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 5ms (ActiveRecord: 0.2ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" = '2014-12-23 15:24:47.800323') LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", "2014-12-23 15:24:47.800323"], ["editor_id", 2], ["updated_at", "2014-12-23 15:24:47.801793"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#undelete as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "editor_id" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["editor_id", 3], ["updated_at", "2014-12-23 15:24:47.805600"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.3ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0014_won't upvote unless authorized -------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.812552"], ["updated_at", "2014-12-23 15:24:47.812552"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.814375"], ["updated_at", "2014-12-23 15:24:47.814375"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:47.816361"], ["updated_at", "2014-12-23 15:24:47.816361"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:47.818805"], ["updated_at", "2014-12-23 15:24:47.818805"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.828334"], ["updated_at", "2014-12-23 15:24:47.828334"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0015_must upvote if authorized --------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.835467"], ["updated_at", "2014-12-23 15:24:47.835467"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.838333"], ["updated_at", "2014-12-23 15:24:47.838333"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:47.841143"], ["updated_at", "2014-12-23 15:24:47.841143"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:47.844393"], ["updated_at", "2014-12-23 15:24:47.844393"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.845841"], ["updated_at", "2014-12-23 15:24:47.845841"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("votable_id", "votable_type", "voter_id", "voter_type", "vote_flag", "vote_weight", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"], ["vote_flag", "t"], ["vote_weight", 1], ["created_at", "2014-12-23 15:24:47.856597"], ["updated_at", "2014-12-23 15:24:47.856597"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 15ms (ActiveRecord: 0.7ms)  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 8ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "votes" SET "vote_flag" = ?, "updated_at" = ? WHERE "votes"."id" = ? [["vote_flag", "f"], ["updated_at", "2014-12-23 15:24:47.879234"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]] Processing by Commontator::CommentsController#upvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.1ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "votes" SET "vote_flag" = ?, "updated_at" = ? WHERE "votes"."id" = ? [["vote_flag", "t"], ["updated_at", "2014-12-23 15:24:47.886442"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 8ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.6ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------- Commontator::CommentsController: test_0016_won't downvote unless authorized ---------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.896846"], ["updated_at", "2014-12-23 15:24:47.896846"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.899966"], ["updated_at", "2014-12-23 15:24:47.899966"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:47.903003"], ["updated_at", "2014-12-23 15:24:47.903003"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:47.906508"], ["updated_at", "2014-12-23 15:24:47.906508"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.915497"], ["updated_at", "2014-12-23 15:24:47.915497"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------------- Commontator::CommentsController: test_0017_must downvote if authorized ----------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.922397"], ["updated_at", "2014-12-23 15:24:47.922397"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.925304"], ["updated_at", "2014-12-23 15:24:47.925304"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:47.928329"], ["updated_at", "2014-12-23 15:24:47.928329"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:47.931683"], ["updated_at", "2014-12-23 15:24:47.931683"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.939838"], ["updated_at", "2014-12-23 15:24:47.939838"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("votable_id", "votable_type", "voter_id", "voter_type", "vote_flag", "vote_weight", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"], ["vote_flag", "f"], ["vote_weight", 1], ["created_at", "2014-12-23 15:24:47.945415"], ["updated_at", "2014-12-23 15:24:47.945415"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 8ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"]]  (0.1ms) SAVEPOINT active_record_1  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 7ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "vote_flag" = ?, "updated_at" = ? WHERE "votes"."id" = ? [["vote_flag", "t"], ["updated_at", "2014-12-23 15:24:47.963337"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]] Processing by Commontator::CommentsController#downvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL ORDER BY "votes"."id" DESC LIMIT 1 [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) UPDATE "votes" SET "vote_flag" = ?, "updated_at" = ? WHERE "votes"."id" = ? [["vote_flag", "f"], ["updated_at", "2014-12-23 15:24:47.969385"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 8ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.5ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------- Commontator::CommentsController: test_0018_won't unvote unless authorized -------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.978541"], ["updated_at", "2014-12-23 15:24:47.978541"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:47.981329"], ["updated_at", "2014-12-23 15:24:47.981329"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:47.984355"], ["updated_at", "2014-12-23 15:24:47.984355"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:47.987706"], ["updated_at", "2014-12-23 15:24:47.987706"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("votable_id", "votable_type", "voter_id", "voter_type", "vote_flag", "vote_weight", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 2], ["voter_type", "DummyUser"], ["vote_flag", "t"], ["vote_weight", 1], ["created_at", "2014-12-23 15:24:47.991063"], ["updated_at", "2014-12-23 15:24:47.991063"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.1ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.000905"], ["updated_at", "2014-12-23 15:24:48.000905"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 2ms (ActiveRecord: 0.1ms) Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.6ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------- Commontator::CommentsController: test_0019_must unvote if authorized --------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.008265"], ["updated_at", "2014-12-23 15:24:48.008265"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.011066"], ["updated_at", "2014-12-23 15:24:48.011066"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:48.013900"], ["updated_at", "2014-12-23 15:24:48.013900"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:48.017106"], ["updated_at", "2014-12-23 15:24:48.017106"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.018519"], ["updated_at", "2014-12-23 15:24:48.018519"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("votable_id", "votable_type", "voter_id", "voter_type", "vote_flag", "vote_weight", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"], ["vote_flag", "t"], ["vote_weight", 1], ["created_at", "2014-12-23 15:24:48.021302"], ["updated_at", "2014-12-23 15:24:48.021302"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.1ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 8ms (ActiveRecord: 0.6ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 4ms (ActiveRecord: 0.2ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "votes" ("votable_id", "votable_type", "voter_id", "voter_type", "vote_flag", "vote_weight", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?) [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"], ["vote_flag", "f"], ["vote_weight", 1], ["created_at", "2014-12-23 15:24:48.043041"], ["updated_at", "2014-12-23 15:24:48.043041"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 1 WHERE "commontator_comments"."id" = ? [["id", 1]] Processing by Commontator::CommentsController#unvote as HTML Parameters: {"id"=>"1"} Commontator::Comment Load (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"]] ActsAsVotable::Vote Load (0.0ms) SELECT "votes".* FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."voter_id" = ? AND "votes"."voter_type" = ? AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"], ["voter_id", 3], ["voter_type", "DummyUser"]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "votes" WHERE "votes"."id" = ? [["id", 2]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_up" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]] SQL (0.0ms) UPDATE "commontator_comments" SET "cached_votes_down" = 0 WHERE "commontator_comments"."id" = ? [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? [["votable_id", 1], ["votable_type", "Commontator::Comment"]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 7ms (ActiveRecord: 0.5ms)  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 't' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.0ms) SELECT COUNT(*) FROM "votes" WHERE "votes"."votable_id" = ? AND "votes"."votable_type" = ? AND "votes"."vote_flag" = 'f' AND "votes"."vote_scope" IS NULL [["votable_id", 1], ["votable_type", "Commontator::Comment"]]  (0.6ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::CommentsController: test_0020_won't send mail if recipients empty ------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.058089"], ["updated_at", "2014-12-23 15:24:48.058089"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.061117"], ["updated_at", "2014-12-23 15:24:48.061117"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:48.064146"], ["updated_at", "2014-12-23 15:24:48.064146"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:48.067479"], ["updated_at", "2014-12-23 15:24:48.067479"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.068976"], ["updated_at", "2014-12-23 15:24:48.068976"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:48.073681"], ["updated_at", "2014-12-23 15:24:48.073681"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.4ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------------- Commontator::CommentsController: test_0021_must send mail if recipients not empty ---------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.080142"], ["updated_at", "2014-12-23 15:24:48.080142"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.082935"], ["updated_at", "2014-12-23 15:24:48.082935"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:48.085707"], ["updated_at", "2014-12-23 15:24:48.085707"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:48.088862"], ["updated_at", "2014-12-23 15:24:48.088862"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.090276"], ["updated_at", "2014-12-23 15:24:48.090276"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 3], ["subscriber_type", "DummyUser"], ["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 3) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 3], ["subscriber_type", "DummyUser"], ["thread_id", 1], ["created_at", "2014-12-23 15:24:48.096580"], ["updated_at", "2014-12-23 15:24:48.096580"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::CommentsController#create as HTML Parameters: {"thread_id"=>"1", "comment"=>{"body"=>"Something else"}} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:48.101251"], ["updated_at", "2014-12-23 15:24:48.101251"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 1]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 3]] Redirected to http://test.host/commontator/threads/1 Completed 302 Found in 6ms (ActiveRecord: 0.4ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------- Commontator::Subscription: test_0001_must count unread comments ---------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.108882"], ["updated_at", "2014-12-23 15:24:48.108882"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.111801"], ["updated_at", "2014-12-23 15:24:48.111801"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:48.114754"], ["updated_at", "2014-12-23 15:24:48.114754"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 1 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_subscriptions" ("thread_id", "subscriber_id", "subscriber_type", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["thread_id", 1], ["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["created_at", "2014-12-23 15:24:48.117664"], ["updated_at", "2014-12-23 15:24:48.117664"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:24:48.117664') [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:48.121799"], ["updated_at", "2014-12-23 15:24:48.121799"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:24:48.117664') [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 1 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 1], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:48.126488"], ["updated_at", "2014-12-23 15:24:48.126488"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:24:48.117664') [["thread_id", 1]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-12-23 15:24:48.129256' WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 1]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:24:48.129256') [["thread_id", 1]]  (0.4ms) rollback transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.134231"], ["updated_at", "2014-12-23 15:24:48.134231"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 1]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 1 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 1], ["created_at", "2014-12-23 15:24:48.136029"], ["updated_at", "2014-12-23 15:24:48.136029"]]  (0.7ms) commit transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------- Commontator::Comment: test_0001_must be votable if acts_as_votable is installed -------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.139547"], ["updated_at", "2014-12-23 15:24:48.139547"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.141126"], ["updated_at", "2014-12-23 15:24:48.141126"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:48.142949"], ["updated_at", "2014-12-23 15:24:48.142949"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.3ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------- Commontator::Comment: test_0002_must know if it has been modified -----------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.145547"], ["updated_at", "2014-12-23 15:24:48.145547"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.147095"], ["updated_at", "2014-12-23 15:24:48.147095"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:48.148806"], ["updated_at", "2014-12-23 15:24:48.148806"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:48.151159"], ["updated_at", "2014-12-23 15:24:48.151159"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["body", "Something else"], ["editor_id", 2], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:24:48.153328"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.5ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------- Commontator::Comment: test_0003_must know if it has been deleted ----------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.156224"], ["updated_at", "2014-12-23 15:24:48.156224"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.159098"], ["updated_at", "2014-12-23 15:24:48.159098"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:48.161993"], ["updated_at", "2014-12-23 15:24:48.161993"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" = '2014-12-23 15:24:48.163932') LIMIT 1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.165773"], ["updated_at", "2014-12-23 15:24:48.165773"]] SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "deleted_at", "editor_type", "editor_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["deleted_at", "2014-12-23 15:24:48.163932"], ["editor_type", "DummyUser"], ["editor_id", 3], ["created_at", "2014-12-23 15:24:48.166786"], ["updated_at", "2014-12-23 15:24:48.166786"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "deleted_at" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["deleted_at", nil], ["updated_at", "2014-12-23 15:24:48.169570"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.6ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------- Commontator::Comment: test_0004_must make proper timestamps -----------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.172646"], ["updated_at", "2014-12-23 15:24:48.172646"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.175941"], ["updated_at", "2014-12-23 15:24:48.175941"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:48.178727"], ["updated_at", "2014-12-23 15:24:48.178727"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:48.181977"], ["updated_at", "2014-12-23 15:24:48.181977"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.184159"], ["updated_at", "2014-12-23 15:24:48.184159"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."id" != 1 AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.0ms) UPDATE "commontator_comments" SET "body" = ?, "editor_id" = ?, "editor_type" = ?, "updated_at" = ? WHERE "commontator_comments"."id" = ? [["body", "Something else"], ["editor_id", 3], ["editor_type", "DummyUser"], ["updated_at", "2014-12-23 15:24:48.186223"], ["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.4ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------ Commontator::SubscriptionsMailer: test_0001_must create deliverable mail ------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.332961"], ["updated_at", "2014-12-23 15:24:48.332961"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.335426"], ["updated_at", "2014-12-23 15:24:48.335426"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:48.337667"], ["updated_at", "2014-12-23 15:24:48.337667"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.338898"], ["updated_at", "2014-12-23 15:24:48.338898"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["created_at", "2014-12-23 15:24:48.341579"], ["updated_at", "2014-12-23 15:24:48.341579"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 3], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 3) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 3], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["created_at", "2014-12-23 15:24:48.343906"], ["updated_at", "2014-12-23 15:24:48.343906"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 2 AND "commontator_comments"."thread_id" = 2 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 2], ["creator_id", 2], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:48.346271"], ["updated_at", "2014-12-23 15:24:48.346271"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 3]] Rendered /Users/dante/Desktop/commontator/app/views/commontator/comments/_body.html.erb (1.0ms) Rendered /Users/dante/Desktop/commontator/app/views/commontator/subscriptions_mailer/comment_created.html.erb (2.2ms) Commontator::SubscriptionsMailer#comment_created: processed outbound mail in 13.4ms Sent mail to Undisclosed Recipients (2.8ms) Date: Tue, 23 Dec 2014 09:24:48 -0600 From: no-reply@dummy.com To: Undisclosed Recipients Message-ID: <5499894059501_49a3ff52e065bb8428@Dantes-MacBook-Pro.local.mail> Subject: Dummy User #2 posted a comment on DummyModel #2 Mime-Version: 1.0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit

Dummy User #2 commented on DummyModel #2:

Something

Click here to view all comments on DummyModel #2.

 (1.1ms) rollback transaction  (0.1ms) begin transaction --------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0001_won't subscribe unless authorized ---------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.371889"], ["updated_at", "2014-12-23 15:24:48.371889"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.380393"], ["updated_at", "2014-12-23 15:24:48.380393"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:48.382656"], ["updated_at", "2014-12-23 15:24:48.382656"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"2"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]] Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["created_at", "2014-12-23 15:24:48.390141"], ["updated_at", "2014-12-23 15:24:48.390141"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 3ms (ActiveRecord: 0.1ms)  (0.6ms) rollback transaction  (0.0ms) begin transaction ---------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0002_must subscribe if authorized ----------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.398912"], ["updated_at", "2014-12-23 15:24:48.398912"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.401821"], ["updated_at", "2014-12-23 15:24:48.401821"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:48.404617"], ["updated_at", "2014-12-23 15:24:48.404617"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["created_at", "2014-12-23 15:24:48.411199"], ["updated_at", "2014-12-23 15:24:48.411199"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 6ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.0ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["created_at", "2014-12-23 15:24:48.419205"], ["updated_at", "2014-12-23 15:24:48.419205"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 4ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.3ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#subscribe as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["created_at", "2014-12-23 15:24:48.426853"], ["updated_at", "2014-12-23 15:24:48.426853"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 5ms (ActiveRecord: 0.3ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.6ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------------------------- Commontator::SubscriptionsController: test_0003_won't unsubscribe unless authorized -----------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.433249"], ["updated_at", "2014-12-23 15:24:48.433249"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.436370"], ["updated_at", "2014-12-23 15:24:48.436370"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:48.439217"], ["updated_at", "2014-12-23 15:24:48.439217"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["created_at", "2014-12-23 15:24:48.442841"], ["updated_at", "2014-12-23 15:24:48.442841"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"2"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]] Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 3ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction ------------------------------------------------------------------------------ Commontator::SubscriptionsController: test_0004_must unsubscribe if authorized ------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.455520"], ["updated_at", "2014-12-23 15:24:48.455520"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.459372"], ["updated_at", "2014-12-23 15:24:48.459372"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:48.461891"], ["updated_at", "2014-12-23 15:24:48.461891"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["created_at", "2014-12-23 15:24:48.465140"], ["updated_at", "2014-12-23 15:24:48.465140"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 1]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 4ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (1.6ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["created_at", "2014-12-23 15:24:48.474270"], ["updated_at", "2014-12-23 15:24:48.474270"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 4ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["created_at", "2014-12-23 15:24:48.484184"], ["updated_at", "2014-12-23 15:24:48.484184"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::SubscriptionsController#unsubscribe as HTML Parameters: {"thread_id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.0ms) SAVEPOINT active_record_1 SQL (0.0ms) DELETE FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? [["id", 3]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.6ms) rollback transaction  (0.1ms) begin transaction ---------------------------------------------------------------------- Commontator::ThreadsController: test_0001_won't show unless authorized ----------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.493013"], ["updated_at", "2014-12-23 15:24:48.493013"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.495492"], ["updated_at", "2014-12-23 15:24:48.495492"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:48.498132"], ["updated_at", "2014-12-23 15:24:48.498132"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms)  (0.4ms) rollback transaction  (0.1ms) begin transaction ----------------------------------------------------------------- Commontator::ThreadsController: test_0002_must show if authorized -----------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.505618"], ["updated_at", "2014-12-23 15:24:48.505618"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.508175"], ["updated_at", "2014-12-23 15:24:48.508175"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:48.510728"], ["updated_at", "2014-12-23 15:24:48.510728"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 2], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]] Redirected to http://test.host/dummy_models/2 Completed 302 Found in 5ms (ActiveRecord: 0.2ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 2], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]] Redirected to http://test.host/dummy_models/2 Completed 302 Found in 3ms (ActiveRecord: 0.2ms) Processing by Commontator::ThreadsController#show as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 2], ["commontable_type", "DummyModel"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]] Redirected to http://test.host/dummy_models/2 Completed 302 Found in 3ms (ActiveRecord: 0.2ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction -------------------------------------------------------------------------------- Commontator::ThreadsController: test_0003_won't close unless authorized and open --------------------------------------------------------------------------------  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.531207"], ["updated_at", "2014-12-23 15:24:48.531207"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.533800"], ["updated_at", "2014-12-23 15:24:48.533800"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:48.536157"], ["updated_at", "2014-12-23 15:24:48.536157"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"2"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:24:48.541723"], ["updated_at", "2014-12-23 15:24:48.542565"], ["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction --------------------------------------------------------------------------- Commontator::ThreadsController: test_0004_must close if authorized and open ---------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.549921"], ["updated_at", "2014-12-23 15:24:48.549921"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.552786"], ["updated_at", "2014-12-23 15:24:48.552786"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:48.555535"], ["updated_at", "2014-12-23 15:24:48.555535"]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:24:48.558977"], ["closer_id", 2], ["closer_type", "DummyUser"], ["updated_at", "2014-12-23 15:24:48.560273"], ["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 5ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", nil], ["updated_at", "2014-12-23 15:24:48.564798"], ["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#close as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:24:48.566736"], ["updated_at", "2014-12-23 15:24:48.568064"], ["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 4ms (ActiveRecord: 0.2ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction ----------------------------------------------------------------------------------- Commontator::ThreadsController: test_0005_won't reopen unless authorized and closed -----------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.573384"], ["updated_at", "2014-12-23 15:24:48.573384"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.576566"], ["updated_at", "2014-12-23 15:24:48.576566"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:48.579389"], ["updated_at", "2014-12-23 15:24:48.579389"]]  (0.0ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:24:48.580594"], ["updated_at", "2014-12-23 15:24:48.581667"], ["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"2"} Completed 403 Forbidden in 0ms (ActiveRecord: 0.0ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Completed 403 Forbidden in 1ms (ActiveRecord: 0.1ms) Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", nil], ["updated_at", "2014-12-23 15:24:48.588170"], ["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 2ms (ActiveRecord: 0.1ms)  (0.5ms) rollback transaction  (0.1ms) begin transaction ------------------------------------------------------------------------------ Commontator::ThreadsController: test_0006_must reopen if authorized and closed ------------------------------------------------------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.594724"], ["updated_at", "2014-12-23 15:24:48.594724"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.597601"], ["updated_at", "2014-12-23 15:24:48.597601"]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:48.600312"], ["updated_at", "2014-12-23 15:24:48.600312"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:24:48.601515"], ["updated_at", "2014-12-23 15:24:48.602555"], ["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", nil], ["updated_at", "2014-12-23 15:24:48.606665"], ["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 5ms (ActiveRecord: 0.3ms)  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:24:48.610885"], ["updated_at", "2014-12-23 15:24:48.611779"], ["id", 2]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Processing by Commontator::ThreadsController#reopen as HTML Parameters: {"id"=>"2"} Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]]  (0.0ms) SAVEPOINT active_record_1 Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."id" != 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.0ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", nil], ["updated_at", "2014-12-23 15:24:48.614689"], ["id", 2]]  (0.0ms) RELEASE SAVEPOINT active_record_1 Redirected to http://test.host/commontator/threads/2 Completed 302 Found in 4ms (ActiveRecord: 0.2ms)  (0.5ms) rollback transaction  (0.0ms) begin transaction -------------------------------------------------------------------- Commontator::ApplicationHelper: test_0001_must print javascript proc --------------------------------------------------------------------  (0.0ms) rollback transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.623488"], ["updated_at", "2014-12-23 15:24:48.623488"]]  (0.7ms) commit transaction  (0.1ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.626804"], ["updated_at", "2014-12-23 15:24:48.626804"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 2]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 2 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 2], ["created_at", "2014-12-23 15:24:48.629204"], ["updated_at", "2014-12-23 15:24:48.629204"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 2) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["created_at", "2014-12-23 15:24:48.633267"], ["updated_at", "2014-12-23 15:24:48.633267"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.635019"], ["updated_at", "2014-12-23 15:24:48.635019"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 3], ["subscriber_type", "DummyUser"], ["thread_id", 2]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 2 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 3) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 3], ["subscriber_type", "DummyUser"], ["thread_id", 2], ["created_at", "2014-12-23 15:24:48.638111"], ["updated_at", "2014-12-23 15:24:48.638111"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 2], ["subscriber_type", "DummyUser"], ["thread_id", 2]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 2]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 3], ["subscriber_type", "DummyUser"], ["thread_id", 2]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 2]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 3]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.642424"], ["updated_at", "2014-12-23 15:24:48.642424"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.644573"], ["updated_at", "2014-12-23 15:24:48.644573"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 3 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 3], ["created_at", "2014-12-23 15:24:48.646204"], ["updated_at", "2014-12-23 15:24:48.646204"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 4], ["subscriber_type", "DummyUser"], ["thread_id", 3]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 3 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 4) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 4], ["subscriber_type", "DummyUser"], ["thread_id", 3], ["created_at", "2014-12-23 15:24:48.649404"], ["updated_at", "2014-12-23 15:24:48.649404"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 4], ["subscriber_type", "DummyUser"], ["thread_id", 3]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 3]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:24:48.649404') [["thread_id", 3]]  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 4 AND "commontator_comments"."thread_id" = 3 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.2ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 3], ["creator_id", 4], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:48.654324"], ["updated_at", "2014-12-23 15:24:48.654324"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 3]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]]  (0.0ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:24:48.649404') [["thread_id", 3]] Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 4], ["subscriber_type", "DummyUser"], ["thread_id", 3]]  (0.0ms) begin transaction SQL (0.1ms) UPDATE "commontator_subscriptions" SET "updated_at" = '2014-12-23 15:24:48.658418' WHERE "commontator_subscriptions"."id" = ? [["id", 3]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."id" = ? LIMIT 1 [["id", 3]] Commontator::Thread Load (0.0ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 3]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 3]]  (0.1ms) SELECT COUNT(*) FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND ("commontator_comments"."created_at" > '2014-12-23 15:24:48.658418') [["thread_id", 3]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.661571"], ["updated_at", "2014-12-23 15:24:48.661571"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.663711"], ["updated_at", "2014-12-23 15:24:48.663711"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 4]] Commontator::Thread Exists (0.0ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 4 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 4], ["created_at", "2014-12-23 15:24:48.665314"], ["updated_at", "2014-12-23 15:24:48.665314"]]  (0.7ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 5], ["subscriber_type", "DummyUser"], ["thread_id", 4]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 4 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 5) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 5], ["subscriber_type", "DummyUser"], ["thread_id", 4], ["created_at", "2014-12-23 15:24:48.668641"], ["updated_at", "2014-12-23 15:24:48.668641"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.670295"], ["updated_at", "2014-12-23 15:24:48.670295"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."subscriber_id" = ? AND "commontator_subscriptions"."subscriber_type" = ? AND "commontator_subscriptions"."thread_id" = ? ORDER BY "commontator_subscriptions"."id" ASC LIMIT 1 [["subscriber_id", 6], ["subscriber_type", "DummyUser"], ["thread_id", 4]]  (0.0ms) begin transaction Commontator::Subscription Exists (0.1ms) SELECT 1 AS one FROM "commontator_subscriptions" WHERE ("commontator_subscriptions"."thread_id" = 4 AND "commontator_subscriptions"."subscriber_type" = 'DummyUser' AND "commontator_subscriptions"."subscriber_id" = 6) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?) [["subscriber_id", 6], ["subscriber_type", "DummyUser"], ["thread_id", 4], ["created_at", "2014-12-23 15:24:48.673380"], ["updated_at", "2014-12-23 15:24:48.673380"]]  (0.6ms) commit transaction Commontator::Subscription Load (0.1ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 4]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 5]] DummyUser Load (0.0ms) SELECT "dummy_users".* FROM "dummy_users" WHERE "dummy_users"."id" = ? LIMIT 1 [["id", 6]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.676291"], ["updated_at", "2014-12-23 15:24:48.676291"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.678354"], ["updated_at", "2014-12-23 15:24:48.678354"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 5 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 5], ["created_at", "2014-12-23 15:24:48.679953"], ["updated_at", "2014-12-23 15:24:48.679953"]]  (0.8ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 7 AND "commontator_comments"."thread_id" = 5 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 5], ["creator_id", 7], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:48.683129"], ["updated_at", "2014-12-23 15:24:48.683129"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 5 AND "commontator_threads"."id" != 5 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:24:48.684756"], ["closer_id", 7], ["closer_type", "DummyUser"], ["updated_at", "2014-12-23 15:24:48.685796"], ["id", 5]]  (0.6ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = ? [["thread_id", 5], ["id", 2]] DummyModel Load (0.1ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 5], ["commontable_type", "DummyModel"]]  (0.0ms) begin transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1  [["id", 5]] SQL (0.2ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "commontable_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["commontable_id", nil], ["commontable_type", nil], ["updated_at", "2014-12-23 15:24:48.690896"], ["id", 5]] Commontator::Thread Exists (0.0ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 5 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_id", "commontable_type", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_id", 5], ["commontable_type", "DummyModel"], ["created_at", "2014-12-23 15:24:48.692245"], ["updated_at", "2014-12-23 15:24:48.692245"]] Commontator::Subscription Load (0.0ms) SELECT "commontator_subscriptions".* FROM "commontator_subscriptions" WHERE "commontator_subscriptions"."thread_id" = ? [["thread_id", 5]]  (0.6ms) commit transaction Commontator::Comment Exists (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = ? [["thread_id", 5], ["id", 2]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 5]] Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."commontable_id" = ? AND "commontator_threads"."commontable_type" = ? LIMIT 1 [["commontable_id", 5], ["commontable_type", "DummyModel"]] Commontator::Comment Exists (0.0ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? AND "commontator_comments"."id" = ? [["thread_id", 6], ["id", 2]]  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.696053"], ["updated_at", "2014-12-23 15:24:48.696053"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.698236"], ["updated_at", "2014-12-23 15:24:48.698236"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 6]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 6 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 6], ["created_at", "2014-12-23 15:24:48.699829"], ["updated_at", "2014-12-23 15:24:48.699829"]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 6 AND "commontator_threads"."id" != 7 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "closer_id" = ?, "closer_type" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", "2014-12-23 15:24:48.701309"], ["closer_id", 8], ["closer_type", "DummyUser"], ["updated_at", "2014-12-23 15:24:48.702222"], ["id", 7]]  (0.6ms) commit transaction  (0.0ms) begin transaction Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 6 AND "commontator_threads"."id" != 7 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) UPDATE "commontator_threads" SET "closed_at" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["closed_at", nil], ["updated_at", "2014-12-23 15:24:48.704529"], ["id", 7]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.706131"], ["updated_at", "2014-12-23 15:24:48.706131"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.708187"], ["updated_at", "2014-12-23 15:24:48.708187"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 7]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 7 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 7], ["created_at", "2014-12-23 15:24:48.709729"], ["updated_at", "2014-12-23 15:24:48.709729"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.711539"], ["updated_at", "2014-12-23 15:24:48.711539"]]  (0.6ms) commit transaction  (0.0ms) begin transaction SQL (0.2ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.713643"], ["updated_at", "2014-12-23 15:24:48.713643"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 8]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 8 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 8], ["created_at", "2014-12-23 15:24:48.715295"], ["updated_at", "2014-12-23 15:24:48.715295"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 10 AND "commontator_comments"."thread_id" = 9 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 9], ["creator_id", 10], ["creator_type", "DummyUser"], ["body", "Something"], ["created_at", "2014-12-23 15:24:48.718261"], ["updated_at", "2014-12-23 15:24:48.718261"]]  (0.7ms) commit transaction  (0.0ms) begin transaction Commontator::Comment Exists (0.1ms) SELECT 1 AS one FROM "commontator_comments" WHERE ("commontator_comments"."body" = 'Something else' AND "commontator_comments"."creator_type" = 'DummyUser' AND "commontator_comments"."creator_id" = 10 AND "commontator_comments"."thread_id" = 9 AND "commontator_comments"."deleted_at" IS NULL) LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_comments" ("thread_id", "creator_id", "creator_type", "body", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["thread_id", 9], ["creator_id", 10], ["creator_type", "DummyUser"], ["body", "Something else"], ["created_at", "2014-12-23 15:24:48.721255"], ["updated_at", "2014-12-23 15:24:48.721255"]]  (0.7ms) commit transaction Commontator::Comment Load (0.2ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? [["thread_id", 9]] Commontator::Comment Load (0.1ms) SELECT "commontator_comments".* FROM "commontator_comments" WHERE "commontator_comments"."thread_id" = ? ORDER BY created_at ASC [["thread_id", 9]]  (0.1ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_users" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.724615"], ["updated_at", "2014-12-23 15:24:48.724615"]]  (0.7ms) commit transaction  (0.0ms) begin transaction SQL (0.1ms) INSERT INTO "dummy_models" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2014-12-23 15:24:48.726873"], ["updated_at", "2014-12-23 15:24:48.726873"]] DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", 9]] Commontator::Thread Exists (0.1ms) SELECT 1 AS one FROM "commontator_threads" WHERE ("commontator_threads"."commontable_id" = 9 AND "commontator_threads"."commontable_type" = 'DummyModel') LIMIT 1 SQL (0.1ms) INSERT INTO "commontator_threads" ("commontable_type", "commontable_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["commontable_type", "DummyModel"], ["commontable_id", 9], ["created_at", "2014-12-23 15:24:48.728534"], ["updated_at", "2014-12-23 15:24:48.728534"]]  (0.7ms) commit transaction  (0.0ms) begin transaction DummyModel Load (0.0ms) SELECT "dummy_models".* FROM "dummy_models" WHERE "dummy_models"."id" = ? LIMIT 1 [["id", nil]] SQL (0.1ms) UPDATE "commontator_threads" SET "commontable_id" = ?, "updated_at" = ? WHERE "commontator_threads"."id" = ? [["commontable_id", nil], ["updated_at", "2014-12-23 15:24:48.730628"], ["id", 10]]  (0.6ms) commit transaction Commontator::Thread Load (0.1ms) SELECT "commontator_threads".* FROM "commontator_threads" WHERE "commontator_threads"."id" = ? LIMIT 1 [["id", 10]]