commontator 4.10.3 → 4.10.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Rakefile +7 -6
- data/app/models/commontator/subscription.rb +4 -2
- data/app/models/commontator/subscription.rb~ +23 -0
- data/app/views/commontator/comments/_votes.html.erb +8 -8
- data/config/locales/{commontator/en.yml → en.yml} +0 -0
- data/lib/commontator/engine.rb +0 -3
- data/lib/commontator/version.rb +1 -1
- data/lib/commontator/version.rb~ +3 -0
- data/spec/controllers/commontator/comments_controller_spec.rb +566 -0
- data/spec/controllers/commontator/comments_controller_spec.rb~ +565 -0
- data/spec/controllers/commontator/subscriptions_controller_spec.rb +102 -0
- data/spec/controllers/commontator/subscriptions_controller_spec.rb~ +101 -0
- data/spec/controllers/commontator/threads_controller_spec.rb +130 -0
- data/spec/controllers/commontator/threads_controller_spec.rb~ +130 -0
- data/spec/dummy/README.md +1 -0
- data/spec/dummy/README.md~ +3 -0
- data/spec/dummy/Rakefile +1 -0
- data/spec/dummy/Rakefile~ +6 -0
- data/spec/dummy/app/assets/javascripts/application.js +1 -0
- data/spec/dummy/app/assets/javascripts/application.js~ +15 -0
- data/spec/dummy/app/assets/stylesheets/application.css +1 -0
- data/spec/dummy/app/assets/stylesheets/application.css~ +13 -0
- data/spec/dummy/app/controllers/application_controller.rb +1 -0
- data/spec/dummy/app/controllers/application_controller.rb~ +3 -0
- data/spec/dummy/app/controllers/dummy_models_controller.rb +12 -6
- data/spec/dummy/app/controllers/dummy_models_controller.rb~ +34 -0
- data/spec/dummy/app/helpers/application_helper.rb +4 -3
- data/spec/dummy/app/helpers/application_helper.rb~ +15 -0
- data/spec/dummy/app/models/dummy_model.rb +1 -0
- data/spec/dummy/app/models/dummy_model.rb~ +3 -0
- data/spec/dummy/app/models/dummy_user.rb +2 -1
- data/spec/dummy/app/models/dummy_user.rb~ +13 -0
- data/spec/dummy/app/views/dummy_model/show.html.erb +1 -0
- data/spec/dummy/app/views/dummy_model/show.html.erb~ +1 -0
- data/spec/dummy/app/views/layouts/application.html.erb +1 -0
- data/spec/dummy/app/views/layouts/application.html.erb~ +14 -0
- data/spec/dummy/config.ru +1 -0
- data/spec/dummy/config.ru~ +4 -0
- data/spec/dummy/config/application.rb +1 -0
- data/spec/dummy/config/application.rb~ +26 -0
- data/spec/dummy/config/boot.rb +1 -0
- data/spec/dummy/config/boot.rb~ +5 -0
- data/spec/dummy/config/database.yml +1 -0
- data/spec/dummy/config/database.yml~ +25 -0
- data/spec/dummy/config/environment.rb +1 -0
- data/spec/dummy/config/environment.rb~ +5 -0
- data/spec/dummy/config/environments/development.rb +1 -0
- data/spec/dummy/config/environments/development.rb~ +31 -0
- data/spec/dummy/config/environments/production.rb +1 -0
- data/spec/dummy/config/environments/production.rb~ +82 -0
- data/spec/dummy/config/environments/test.rb +1 -0
- data/spec/dummy/config/environments/test.rb~ +40 -0
- data/spec/dummy/config/initializers/backtrace_silencers.rb +1 -0
- data/spec/dummy/config/initializers/backtrace_silencers.rb~ +7 -0
- data/spec/dummy/config/initializers/commontator.rb +1 -0
- data/spec/dummy/config/initializers/commontator.rb~ +14 -0
- data/spec/dummy/config/initializers/filter_parameter_logging.rb +1 -0
- data/spec/dummy/config/initializers/filter_parameter_logging.rb~ +4 -0
- data/spec/dummy/config/initializers/inflections.rb +1 -0
- data/spec/dummy/config/initializers/inflections.rb~ +16 -0
- data/spec/dummy/config/initializers/mime_types.rb +1 -0
- data/spec/dummy/config/initializers/mime_types.rb~ +5 -0
- data/spec/dummy/config/initializers/secret_token.rb +1 -0
- data/spec/dummy/config/initializers/secret_token.rb~ +12 -0
- data/spec/dummy/config/initializers/session_store.rb +1 -0
- data/spec/dummy/config/initializers/session_store.rb~ +3 -0
- data/spec/dummy/config/initializers/wrap_parameters.rb +1 -0
- data/spec/dummy/config/initializers/wrap_parameters.rb~ +14 -0
- data/spec/dummy/config/routes.rb +2 -1
- data/spec/dummy/config/routes.rb~ +7 -0
- data/spec/dummy/db/migrate/1_create_dummy_models.rb +1 -0
- data/spec/dummy/db/migrate/1_create_dummy_models.rb~ +7 -0
- data/spec/dummy/db/migrate/2_create_dummy_users.rb +1 -0
- data/spec/dummy/db/migrate/2_create_dummy_users.rb~ +7 -0
- data/spec/dummy/db/migrate/3_acts_as_votable_migration.rb +1 -0
- data/spec/dummy/db/migrate/3_acts_as_votable_migration.rb~ +27 -0
- data/spec/dummy/db/test.sqlite3 +0 -0
- data/spec/dummy/log/development.log +33 -119
- data/spec/dummy/log/test.log +33394 -31595
- data/spec/dummy/public/404.html +1 -0
- data/spec/dummy/public/404.html~ +26 -0
- data/spec/dummy/public/422.html +1 -0
- data/spec/dummy/public/422.html~ +26 -0
- data/spec/dummy/public/500.html +1 -0
- data/spec/dummy/public/500.html~ +25 -0
- data/spec/dummy/script/rails +1 -0
- data/spec/dummy/script/rails~ +6 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/{72b63dddbc5c995f79af8e3c94904fd9 → 02d4b791eb831cf2057bf4703a1218d1} +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/{a77b1a9223d168112e1705c29220116f → 0f196a1a50363b0a076ec6e1ee5417f6} +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/{afa63eb365bdf4f42584b17ac9176b9d → a3fb9025f90ff05a6fd4afc7ded2692c} +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/a41c8be5379abec3c0d0d98e2f0d5609 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/{a473b3873e554893372a53d71f5e9879 → c69ee3cc5796188d873574179290a6ef} +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/{f721383d531f067d82b071e14aed7a92 → e1f674c11941d62aac1764ef3a7134e4} +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/{d2244ccef8e05bb993f75715af0344cc → e85565206c3e5fdf9dfeb367c85557b1} +0 -0
- data/spec/helpers/commontator/application_helper_spec.rb +10 -0
- data/spec/helpers/commontator/application_helper_spec.rb~ +9 -0
- data/spec/lib/commontator/acts_as_commontable_spec.rb +16 -15
- data/spec/lib/commontator/acts_as_commontable_spec.rb~ +25 -0
- data/spec/lib/commontator/acts_as_commontator_spec.rb +17 -16
- data/spec/lib/commontator/acts_as_commontator_spec.rb~ +52 -0
- data/spec/lib/commontator/commontable_config_spec.rb +9 -8
- data/spec/lib/commontator/commontable_config_spec.rb~ +29 -0
- data/spec/lib/commontator/commontator_config_spec.rb +9 -8
- data/spec/lib/commontator/commontator_config_spec.rb~ +29 -0
- data/spec/lib/commontator/controller_includes_spec.rb +10 -7
- data/spec/lib/commontator/controller_includes_spec.rb~ +18 -0
- data/spec/lib/commontator/shared_helper_spec.rb +14 -9
- data/spec/lib/commontator/shared_helper_spec.rb~ +22 -0
- data/spec/lib/commontator_spec.rb +7 -6
- data/spec/lib/commontator_spec.rb~ +26 -0
- data/spec/mailers/commontator/subscriptions_mailer_spec.rb +30 -0
- data/spec/{app/mailers/commontator/subscriptions_mailer_spec.rb → mailers/commontator/subscriptions_mailer_spec.rb~} +12 -12
- data/spec/models/commontator/comment_spec.rb +82 -0
- data/spec/models/commontator/comment_spec.rb~ +82 -0
- data/spec/{app/models → models}/commontator/subscription_spec.rb +14 -13
- data/spec/models/commontator/subscription_spec.rb~ +38 -0
- data/spec/models/commontator/thread_spec.rb +122 -0
- data/spec/{app/models/commontator/thread_spec.rb → models/commontator/thread_spec.rb~} +52 -50
- data/spec/rails_helper.rb +71 -0
- data/spec/rails_helper.rb~ +74 -0
- data/spec/spec_helper.rb +77 -27
- data/spec/spec_helper.rb~ +86 -0
- metadata +184 -78
- data/spec/app/controllers/commontator/comments_controller_spec.rb +0 -582
- data/spec/app/controllers/commontator/subscriptions_controller_spec.rb +0 -99
- data/spec/app/controllers/commontator/threads_controller_spec.rb +0 -127
- data/spec/app/helpers/commontator/application_helper_spec.rb +0 -9
- data/spec/app/models/commontator/comment_spec.rb +0 -73
- data/spec/dummy/db/development.sqlite3 +0 -0
- data/spec/dummy/tmp/cache/assets/test/sprockets/decb63cac838a5314aa0c22a979f5ac9 +0 -0
@@ -0,0 +1,40 @@
|
|
1
|
+
Dummy::Application.configure do
|
2
|
+
# Settings specified here will take precedence over those in config/application.rb.
|
3
|
+
|
4
|
+
# The test environment is used exclusively to run your application's
|
5
|
+
# test suite. You never need to work with it otherwise. Remember that
|
6
|
+
# your test database is "scratch space" for the test suite and is wiped
|
7
|
+
# and recreated between test runs. Don't rely on the data there!
|
8
|
+
config.cache_classes = true
|
9
|
+
|
10
|
+
# Do not eager load code on boot. This avoids loading your whole application
|
11
|
+
# just for the purpose of running a single test. If you are using a tool that
|
12
|
+
# preloads Rails for running tests, you may have to set it to true.
|
13
|
+
config.eager_load = false
|
14
|
+
|
15
|
+
# Configure static asset server for tests with Cache-Control for performance.
|
16
|
+
config.serve_static_files = true
|
17
|
+
config.static_cache_control = "public, max-age=3600"
|
18
|
+
|
19
|
+
# Show full error reports and disable caching.
|
20
|
+
config.consider_all_requests_local = true
|
21
|
+
config.action_controller.perform_caching = false
|
22
|
+
|
23
|
+
# Raise exceptions instead of rendering exception templates.
|
24
|
+
config.action_dispatch.show_exceptions = false
|
25
|
+
|
26
|
+
# Disable request forgery protection in test environment.
|
27
|
+
config.action_controller.allow_forgery_protection = false
|
28
|
+
|
29
|
+
# Tell Action Mailer not to deliver emails to the real world.
|
30
|
+
# The :test delivery method accumulates sent emails in the
|
31
|
+
# ActionMailer::Base.deliveries array.
|
32
|
+
config.action_mailer.delivery_method = :test
|
33
|
+
|
34
|
+
config.action_mailer.default_url_options = { :host => "test.example.com" }
|
35
|
+
|
36
|
+
# Print deprecation notices to the stderr.
|
37
|
+
config.active_support.deprecation = :stderr
|
38
|
+
|
39
|
+
config.active_support.test_order = :sorted
|
40
|
+
end
|
@@ -0,0 +1,7 @@
|
|
1
|
+
# Be sure to restart your server when you modify this file.
|
2
|
+
|
3
|
+
# You can add backtrace silencers for libraries that you're using but don't wish to see in your backtraces.
|
4
|
+
# Rails.backtrace_cleaner.add_silencer { |line| line =~ /my_noisy_library/ }
|
5
|
+
|
6
|
+
# You can also remove all the silencers if you're trying to debug a problem that might stem from framework code.
|
7
|
+
# Rails.backtrace_cleaner.remove_silencers!
|
@@ -0,0 +1,14 @@
|
|
1
|
+
# Dummy application configuration file
|
2
|
+
Commontator.configure do |config|
|
3
|
+
config.javascript_proc = lambda { |view| '// Some javascript' }
|
4
|
+
|
5
|
+
config.user_name_proc = lambda { |user| user.try(:name) || 'Anonymous' }
|
6
|
+
|
7
|
+
config.thread_read_proc = lambda { |thread, user| user && user.can_read }
|
8
|
+
|
9
|
+
config.thread_moderator_proc = lambda { |thread, user| user.is_admin || user.can_edit }
|
10
|
+
|
11
|
+
config.comment_voting = :ld
|
12
|
+
|
13
|
+
config.thread_subscription = :m
|
14
|
+
end
|
@@ -0,0 +1,16 @@
|
|
1
|
+
# Be sure to restart your server when you modify this file.
|
2
|
+
|
3
|
+
# Add new inflection rules using the following format. Inflections
|
4
|
+
# are locale specific, and you may define rules for as many different
|
5
|
+
# locales as you wish. All of these examples are active by default:
|
6
|
+
# ActiveSupport::Inflector.inflections(:en) do |inflect|
|
7
|
+
# inflect.plural /^(ox)$/i, '\1en'
|
8
|
+
# inflect.singular /^(ox)en/i, '\1'
|
9
|
+
# inflect.irregular 'person', 'people'
|
10
|
+
# inflect.uncountable %w( fish sheep )
|
11
|
+
# end
|
12
|
+
|
13
|
+
# These inflection rules are supported but not enabled by default:
|
14
|
+
# ActiveSupport::Inflector.inflections(:en) do |inflect|
|
15
|
+
# inflect.acronym 'RESTful'
|
16
|
+
# end
|
@@ -0,0 +1,12 @@
|
|
1
|
+
# Be sure to restart your server when you modify this file.
|
2
|
+
|
3
|
+
# Your secret key is used for verifying the integrity of signed cookies.
|
4
|
+
# If you change this key, all old signed cookies will become invalid!
|
5
|
+
|
6
|
+
# Make sure the secret is at least 30 characters and all random,
|
7
|
+
# no regular words or you'll be exposed to dictionary attacks.
|
8
|
+
# You can use `rake secret` to generate a secure secret key.
|
9
|
+
|
10
|
+
# Make sure your secret_key_base is kept private
|
11
|
+
# if you're sharing your code publicly.
|
12
|
+
Dummy::Application.config.secret_key_base = 'dummy'
|
@@ -0,0 +1,14 @@
|
|
1
|
+
# Be sure to restart your server when you modify this file.
|
2
|
+
|
3
|
+
# This file contains settings for ActionController::ParamsWrapper which
|
4
|
+
# is enabled by default.
|
5
|
+
|
6
|
+
# Enable parameter wrapping for JSON. You can disable this by setting :format to an empty array.
|
7
|
+
ActiveSupport.on_load(:action_controller) do
|
8
|
+
wrap_parameters format: [:json] if respond_to?(:wrap_parameters)
|
9
|
+
end
|
10
|
+
|
11
|
+
# To enable root element in JSON for ActiveRecord objects.
|
12
|
+
# ActiveSupport.on_load(:active_record) do
|
13
|
+
# self.include_root_in_json = true
|
14
|
+
# end
|
data/spec/dummy/config/routes.rb
CHANGED
@@ -0,0 +1,27 @@
|
|
1
|
+
class ActsAsVotableMigration < ActiveRecord::Migration
|
2
|
+
def self.up
|
3
|
+
create_table :votes do |t|
|
4
|
+
|
5
|
+
t.references :votable, :polymorphic => true
|
6
|
+
t.references :voter, :polymorphic => true
|
7
|
+
|
8
|
+
t.boolean :vote_flag
|
9
|
+
t.string :vote_scope
|
10
|
+
t.integer :vote_weight
|
11
|
+
|
12
|
+
t.timestamps
|
13
|
+
end
|
14
|
+
|
15
|
+
if ActiveRecord::VERSION::MAJOR < 4
|
16
|
+
add_index :votes, [:votable_id, :votable_type]
|
17
|
+
add_index :votes, [:voter_id, :voter_type]
|
18
|
+
end
|
19
|
+
|
20
|
+
add_index :votes, [:voter_id, :voter_type, :vote_scope]
|
21
|
+
add_index :votes, [:votable_id, :votable_type, :vote_scope]
|
22
|
+
end
|
23
|
+
|
24
|
+
def self.down
|
25
|
+
drop_table :votes
|
26
|
+
end
|
27
|
+
end
|
data/spec/dummy/db/test.sqlite3
CHANGED
Binary file
|
@@ -1,103 +1,23 @@
|
|
1
|
-
[1m[36m (
|
1
|
+
[1m[36m (4.4ms)[0m [1mCREATE 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) [0m
|
2
2
|
[1m[35m (0.1ms)[0m select sqlite_version(*)
|
3
|
-
[1m[36m (
|
4
|
-
[1m[35mActiveRecord::SchemaMigration Load (0.1ms)[0m SELECT "schema_migrations".* FROM "schema_migrations"
|
5
|
-
Migrating to InstallCommontator (0)
|
6
|
-
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
7
|
-
[1m[35m (0.4ms)[0m 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)
|
8
|
-
[1m[36m (0.1ms)[0m [1mCREATE INDEX "index_commontator_comments_on_c_id_and_c_type_and_t_id" ON "commontator_comments" ("creator_id", "creator_type", "thread_id")[0m
|
3
|
+
[1m[36m (2.9ms)[0m [1mCREATE INDEX "index_commontator_comments_on_cached_votes_down" ON "commontator_comments" ("cached_votes_down")[0m
|
9
4
|
[1m[35m (0.1ms)[0m SELECT sql
|
10
5
|
FROM sqlite_master
|
11
|
-
WHERE name='
|
6
|
+
WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'
|
12
7
|
UNION ALL
|
13
8
|
SELECT sql
|
14
9
|
FROM sqlite_temp_master
|
15
|
-
WHERE name='
|
10
|
+
WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'
|
16
11
|
|
17
|
-
[1m[36m (
|
12
|
+
[1m[36m (2.6ms)[0m [1mCREATE INDEX "index_commontator_comments_on_cached_votes_up" ON "commontator_comments" ("cached_votes_up")[0m
|
18
13
|
[1m[35m (0.1ms)[0m SELECT sql
|
19
|
-
FROM sqlite_master
|
20
|
-
WHERE name='index_commontator_comments_on_thread_id_and_created_at' AND type='index'
|
21
|
-
UNION ALL
|
22
|
-
SELECT sql
|
23
|
-
FROM sqlite_temp_master
|
24
|
-
WHERE name='index_commontator_comments_on_thread_id_and_created_at' AND type='index'
|
25
|
-
|
26
|
-
[1m[36m (0.1ms)[0m [1m SELECT sql
|
27
|
-
FROM sqlite_master
|
28
|
-
WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index'
|
29
|
-
UNION ALL
|
30
|
-
SELECT sql
|
31
|
-
FROM sqlite_temp_master
|
32
|
-
WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index'
|
33
|
-
[0m
|
34
|
-
[1m[35m (0.1ms)[0m CREATE INDEX "index_commontator_comments_on_cached_votes_up" ON "commontator_comments" ("cached_votes_up")
|
35
|
-
[1m[36m (0.1ms)[0m [1m SELECT sql
|
36
14
|
FROM sqlite_master
|
37
15
|
WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'
|
38
16
|
UNION ALL
|
39
17
|
SELECT sql
|
40
18
|
FROM sqlite_temp_master
|
41
19
|
WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'
|
42
|
-
[0m
|
43
|
-
[1m[35m (0.1ms)[0m SELECT sql
|
44
|
-
FROM sqlite_master
|
45
|
-
WHERE name='index_commontator_comments_on_thread_id_and_created_at' AND type='index'
|
46
|
-
UNION ALL
|
47
|
-
SELECT sql
|
48
|
-
FROM sqlite_temp_master
|
49
|
-
WHERE name='index_commontator_comments_on_thread_id_and_created_at' AND type='index'
|
50
20
|
|
51
|
-
[1m[36m (0.1ms)[0m [1m SELECT sql
|
52
|
-
FROM sqlite_master
|
53
|
-
WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index'
|
54
|
-
UNION ALL
|
55
|
-
SELECT sql
|
56
|
-
FROM sqlite_temp_master
|
57
|
-
WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index'
|
58
|
-
[0m
|
59
|
-
[1m[35m (0.1ms)[0m CREATE INDEX "index_commontator_comments_on_cached_votes_down" ON "commontator_comments" ("cached_votes_down")
|
60
|
-
[1m[36m (0.3ms)[0m [1mCREATE 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) [0m
|
61
|
-
[1m[35m (0.5ms)[0m CREATE UNIQUE INDEX "index_commontator_subscriptions_on_s_id_and_s_type_and_t_id" ON "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id")
|
62
|
-
[1m[36m (0.1ms)[0m [1m SELECT sql
|
63
|
-
FROM sqlite_master
|
64
|
-
WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index'
|
65
|
-
UNION ALL
|
66
|
-
SELECT sql
|
67
|
-
FROM sqlite_temp_master
|
68
|
-
WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index'
|
69
|
-
[0m
|
70
|
-
[1m[35m (0.1ms)[0m CREATE INDEX "index_commontator_subscriptions_on_thread_id" ON "commontator_subscriptions" ("thread_id")
|
71
|
-
[1m[36m (0.1ms)[0m [1mCREATE 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) [0m
|
72
|
-
[1m[35m (0.1ms)[0m CREATE UNIQUE INDEX "index_commontator_threads_on_c_id_and_c_type" ON "commontator_threads" ("commontable_id", "commontable_type")
|
73
|
-
[1m[36mSQL (0.1ms)[0m [1mINSERT INTO "schema_migrations" ("version") VALUES (?)[0m [["version", "0"]]
|
74
|
-
[1m[35m (0.7ms)[0m commit transaction
|
75
|
-
Migrating to CreateDummyModels (1)
|
76
|
-
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
77
|
-
[1m[35m (0.2ms)[0m CREATE TABLE "dummy_models" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)
|
78
|
-
[1m[36mSQL (0.1ms)[0m [1mINSERT INTO "schema_migrations" ("version") VALUES (?)[0m [["version", "1"]]
|
79
|
-
[1m[35m (0.6ms)[0m commit transaction
|
80
|
-
Migrating to CreateDummyUsers (2)
|
81
|
-
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
82
|
-
[1m[35m (0.2ms)[0m CREATE TABLE "dummy_users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)
|
83
|
-
[1m[36mSQL (0.1ms)[0m [1mINSERT INTO "schema_migrations" ("version") VALUES (?)[0m [["version", "2"]]
|
84
|
-
[1m[35m (0.6ms)[0m commit transaction
|
85
|
-
Migrating to ActsAsVotableMigration (3)
|
86
|
-
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
87
|
-
[1m[35m (0.3ms)[0m 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)
|
88
|
-
[1m[36m (0.1ms)[0m [1mCREATE INDEX "index_votes_on_voter_id_and_voter_type_and_vote_scope" ON "votes" ("voter_id", "voter_type", "vote_scope")[0m
|
89
|
-
[1m[35m (0.1ms)[0m SELECT sql
|
90
|
-
FROM sqlite_master
|
91
|
-
WHERE name='index_votes_on_voter_id_and_voter_type_and_vote_scope' AND type='index'
|
92
|
-
UNION ALL
|
93
|
-
SELECT sql
|
94
|
-
FROM sqlite_temp_master
|
95
|
-
WHERE name='index_votes_on_voter_id_and_voter_type_and_vote_scope' AND type='index'
|
96
|
-
|
97
|
-
[1m[36m (0.1ms)[0m [1mCREATE INDEX "index_votes_on_votable_id_and_votable_type_and_vote_scope" ON "votes" ("votable_id", "votable_type", "vote_scope")[0m
|
98
|
-
[1m[35mSQL (0.1ms)[0m INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "3"]]
|
99
|
-
[1m[36m (0.7ms)[0m [1mcommit transaction[0m
|
100
|
-
[1m[35mActiveRecord::SchemaMigration Load (0.1ms)[0m SELECT "schema_migrations".* FROM "schema_migrations"
|
101
21
|
[1m[36m (0.1ms)[0m [1m SELECT sql
|
102
22
|
FROM sqlite_master
|
103
23
|
WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'
|
@@ -106,68 +26,62 @@ Migrating to ActsAsVotableMigration (3)
|
|
106
26
|
FROM sqlite_temp_master
|
107
27
|
WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'
|
108
28
|
[0m
|
109
|
-
[1m[35m (
|
29
|
+
[1m[35m (2.5ms)[0m CREATE INDEX "index_commontator_comments_on_c_id_and_c_type_and_t_id" ON "commontator_comments" ("creator_id", "creator_type", "thread_id")
|
30
|
+
[1m[36m (0.2ms)[0m [1m SELECT sql
|
110
31
|
FROM sqlite_master
|
111
|
-
WHERE name='
|
112
|
-
UNION ALL
|
113
|
-
SELECT sql
|
114
|
-
FROM sqlite_temp_master
|
115
|
-
WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'
|
116
|
-
|
117
|
-
[1m[36m (0.1ms)[0m [1m SELECT sql
|
118
|
-
FROM sqlite_master
|
119
|
-
WHERE name='index_commontator_comments_on_thread_id_and_created_at' AND type='index'
|
32
|
+
WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index'
|
120
33
|
UNION ALL
|
121
34
|
SELECT sql
|
122
35
|
FROM sqlite_temp_master
|
123
|
-
WHERE name='
|
36
|
+
WHERE name='index_commontator_comments_on_c_id_and_c_type_and_t_id' AND type='index'
|
124
37
|
[0m
|
125
38
|
[1m[35m (0.1ms)[0m SELECT sql
|
126
39
|
FROM sqlite_master
|
127
|
-
WHERE name='
|
40
|
+
WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'
|
128
41
|
UNION ALL
|
129
42
|
SELECT sql
|
130
43
|
FROM sqlite_temp_master
|
131
|
-
WHERE name='
|
44
|
+
WHERE name='index_commontator_comments_on_cached_votes_up' AND type='index'
|
132
45
|
|
133
46
|
[1m[36m (0.1ms)[0m [1m SELECT sql
|
134
47
|
FROM sqlite_master
|
135
|
-
WHERE name='
|
48
|
+
WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'
|
136
49
|
UNION ALL
|
137
50
|
SELECT sql
|
138
51
|
FROM sqlite_temp_master
|
139
|
-
WHERE name='
|
52
|
+
WHERE name='index_commontator_comments_on_cached_votes_down' AND type='index'
|
140
53
|
[0m
|
141
|
-
[1m[35m (
|
54
|
+
[1m[35m (3.1ms)[0m CREATE INDEX "index_commontator_comments_on_thread_id_and_created_at" ON "commontator_comments" ("thread_id", "created_at")
|
55
|
+
[1m[36m (3.1ms)[0m [1mCREATE 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) [0m
|
56
|
+
[1m[35m (3.0ms)[0m CREATE UNIQUE INDEX "index_commontator_subscriptions_on_s_id_and_s_type_and_t_id" ON "commontator_subscriptions" ("subscriber_id", "subscriber_type", "thread_id")
|
57
|
+
[1m[36m (0.2ms)[0m [1m SELECT sql
|
142
58
|
FROM sqlite_master
|
143
59
|
WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index'
|
144
60
|
UNION ALL
|
145
61
|
SELECT sql
|
146
62
|
FROM sqlite_temp_master
|
147
63
|
WHERE name='index_commontator_subscriptions_on_s_id_and_s_type_and_t_id' AND type='index'
|
148
|
-
|
149
|
-
[1m[36m (0.1ms)[0m [1m SELECT sql
|
150
|
-
FROM sqlite_master
|
151
|
-
WHERE name='index_commontator_threads_on_c_id_and_c_type' AND type='index'
|
152
|
-
UNION ALL
|
153
|
-
SELECT sql
|
154
|
-
FROM sqlite_temp_master
|
155
|
-
WHERE name='index_commontator_threads_on_c_id_and_c_type' AND type='index'
|
156
64
|
[0m
|
157
|
-
[1m[35m (
|
65
|
+
[1m[35m (2.9ms)[0m CREATE INDEX "index_commontator_subscriptions_on_thread_id" ON "commontator_subscriptions" ("thread_id")
|
66
|
+
[1m[36m (2.8ms)[0m [1mCREATE 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) [0m
|
67
|
+
[1m[35m (3.4ms)[0m CREATE UNIQUE INDEX "index_commontator_threads_on_c_id_and_c_type" ON "commontator_threads" ("commontable_id", "commontable_type")
|
68
|
+
[1m[36m (3.7ms)[0m [1mCREATE TABLE "dummy_models" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime) [0m
|
69
|
+
[1m[35m (3.1ms)[0m CREATE TABLE "dummy_users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime)
|
70
|
+
[1m[36m (3.7ms)[0m [1mCREATE 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) [0m
|
71
|
+
[1m[35m (2.9ms)[0m CREATE INDEX "index_votes_on_votable_id_and_votable_type_and_vote_scope" ON "votes" ("votable_id", "votable_type", "vote_scope")
|
72
|
+
[1m[36m (0.2ms)[0m [1m SELECT sql
|
158
73
|
FROM sqlite_master
|
159
74
|
WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index'
|
160
75
|
UNION ALL
|
161
76
|
SELECT sql
|
162
77
|
FROM sqlite_temp_master
|
163
78
|
WHERE name='index_votes_on_votable_id_and_votable_type_and_vote_scope' AND type='index'
|
164
|
-
|
165
|
-
[1m[36m (0.1ms)[0m [1m SELECT sql
|
166
|
-
FROM sqlite_master
|
167
|
-
WHERE name='index_votes_on_voter_id_and_voter_type_and_vote_scope' AND type='index'
|
168
|
-
UNION ALL
|
169
|
-
SELECT sql
|
170
|
-
FROM sqlite_temp_master
|
171
|
-
WHERE name='index_votes_on_voter_id_and_voter_type_and_vote_scope' AND type='index'
|
172
79
|
[0m
|
173
|
-
[1m[
|
80
|
+
[1m[35m (3.0ms)[0m CREATE INDEX "index_votes_on_voter_id_and_voter_type_and_vote_scope" ON "votes" ("voter_id", "voter_type", "vote_scope")
|
81
|
+
[1m[36m (2.9ms)[0m [1mCREATE TABLE "schema_migrations" ("version" varchar NOT NULL) [0m
|
82
|
+
[1m[35m (3.0ms)[0m CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
|
83
|
+
[1m[36m (0.1ms)[0m [1mSELECT version FROM "schema_migrations"[0m
|
84
|
+
[1m[35m (2.7ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('3')
|
85
|
+
[1m[36m (2.6ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('1')[0m
|
86
|
+
[1m[35m (2.1ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('2')
|
87
|
+
[1m[36m (3.4ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('0')[0m
|