custom_emails 0.0.1
Sign up to get free protection for your applications and to get access to all the features.
- data/Rakefile +34 -0
- data/app/mailers/custom_emails/mailer.rb +22 -0
- data/app/models/custom_emails/email.rb +15 -0
- data/app/models/custom_emails/email_kind.rb +8 -0
- data/db/migrate/20131018141445_create_custom_emails_emails.rb +17 -0
- data/db/migrate/20131018143726_create_custom_emails_email_kinds.rb +17 -0
- data/lib/custom_emails.rb +12 -0
- data/lib/custom_emails/engine.rb +5 -0
- data/lib/custom_emails/models.rb +17 -0
- data/lib/custom_emails/orm/active_record.rb +1 -0
- data/lib/custom_emails/version.rb +3 -0
- data/lib/generators/custom_emails/install_generator.rb +11 -0
- data/lib/generators/templates/custom_emails.rb +21 -0
- data/lib/tasks/custom_emails_tasks.rake +4 -0
- data/test/custom_emails_test.rb +7 -0
- data/test/dummy/README.rdoc +28 -0
- data/test/dummy/Rakefile +6 -0
- data/test/dummy/app/assets/javascripts/application.js +13 -0
- data/test/dummy/app/assets/stylesheets/application.css +13 -0
- data/test/dummy/app/controllers/application_controller.rb +5 -0
- data/test/dummy/app/helpers/application_helper.rb +2 -0
- data/test/dummy/app/models/example.rb +2 -0
- data/test/dummy/app/views/layouts/application.html.erb +14 -0
- data/test/dummy/bin/bundle +3 -0
- data/test/dummy/bin/rails +4 -0
- data/test/dummy/bin/rake +4 -0
- data/test/dummy/config.ru +4 -0
- data/test/dummy/config/application.rb +23 -0
- data/test/dummy/config/boot.rb +5 -0
- data/test/dummy/config/database.yml +25 -0
- data/test/dummy/config/environment.rb +5 -0
- data/test/dummy/config/environments/development.rb +29 -0
- data/test/dummy/config/environments/production.rb +80 -0
- data/test/dummy/config/environments/test.rb +36 -0
- data/test/dummy/config/initializers/backtrace_silencers.rb +7 -0
- data/test/dummy/config/initializers/custom_emails.rb +10 -0
- data/test/dummy/config/initializers/filter_parameter_logging.rb +4 -0
- data/test/dummy/config/initializers/inflections.rb +16 -0
- data/test/dummy/config/initializers/mime_types.rb +5 -0
- data/test/dummy/config/initializers/secret_token.rb +12 -0
- data/test/dummy/config/initializers/session_store.rb +3 -0
- data/test/dummy/config/initializers/wrap_parameters.rb +14 -0
- data/test/dummy/config/locales/en.yml +23 -0
- data/test/dummy/config/routes.rb +56 -0
- data/test/dummy/db/development.sqlite3 +0 -0
- data/test/dummy/db/migrate/20131018164626_create_examples.rb +6 -0
- data/test/dummy/db/schema.rb +44 -0
- data/test/dummy/db/test.sqlite3 +0 -0
- data/test/dummy/log/development.log +1201 -0
- data/test/dummy/log/test.log +3167 -0
- data/test/dummy/public/404.html +58 -0
- data/test/dummy/public/422.html +58 -0
- data/test/dummy/public/500.html +57 -0
- data/test/dummy/public/favicon.ico +0 -0
- data/test/fixtures/custom_emails/email_kinds.yml +11 -0
- data/test/fixtures/custom_emails/emails.yml +0 -0
- data/test/integration/navigation_test.rb +10 -0
- data/test/lib/models_test.rb +53 -0
- data/test/mailers/custom_emails/mailer_test.rb +47 -0
- data/test/models/custom_emails/email_kind_test.rb +9 -0
- data/test/models/custom_emails/email_test.rb +42 -0
- data/test/test_helper.rb +16 -0
- data/test/test_models.rb +3 -0
- metadata +211 -0
@@ -0,0 +1,80 @@
|
|
1
|
+
Dummy::Application.configure do
|
2
|
+
# Settings specified here will take precedence over those in config/application.rb.
|
3
|
+
|
4
|
+
# Code is not reloaded between requests.
|
5
|
+
config.cache_classes = true
|
6
|
+
|
7
|
+
# Eager load code on boot. This eager loads most of Rails and
|
8
|
+
# your application in memory, allowing both thread web servers
|
9
|
+
# and those relying on copy on write to perform better.
|
10
|
+
# Rake tasks automatically ignore this option for performance.
|
11
|
+
config.eager_load = true
|
12
|
+
|
13
|
+
# Full error reports are disabled and caching is turned on.
|
14
|
+
config.consider_all_requests_local = false
|
15
|
+
config.action_controller.perform_caching = true
|
16
|
+
|
17
|
+
# Enable Rack::Cache to put a simple HTTP cache in front of your application
|
18
|
+
# Add `rack-cache` to your Gemfile before enabling this.
|
19
|
+
# For large-scale production use, consider using a caching reverse proxy like nginx, varnish or squid.
|
20
|
+
# config.action_dispatch.rack_cache = true
|
21
|
+
|
22
|
+
# Disable Rails's static asset server (Apache or nginx will already do this).
|
23
|
+
config.serve_static_assets = false
|
24
|
+
|
25
|
+
# Compress JavaScripts and CSS.
|
26
|
+
config.assets.js_compressor = :uglifier
|
27
|
+
# config.assets.css_compressor = :sass
|
28
|
+
|
29
|
+
# Do not fallback to assets pipeline if a precompiled asset is missed.
|
30
|
+
config.assets.compile = false
|
31
|
+
|
32
|
+
# Generate digests for assets URLs.
|
33
|
+
config.assets.digest = true
|
34
|
+
|
35
|
+
# Version of your assets, change this if you want to expire all your assets.
|
36
|
+
config.assets.version = '1.0'
|
37
|
+
|
38
|
+
# Specifies the header that your server uses for sending files.
|
39
|
+
# config.action_dispatch.x_sendfile_header = "X-Sendfile" # for apache
|
40
|
+
# config.action_dispatch.x_sendfile_header = 'X-Accel-Redirect' # for nginx
|
41
|
+
|
42
|
+
# Force all access to the app over SSL, use Strict-Transport-Security, and use secure cookies.
|
43
|
+
# config.force_ssl = true
|
44
|
+
|
45
|
+
# Set to :debug to see everything in the log.
|
46
|
+
config.log_level = :info
|
47
|
+
|
48
|
+
# Prepend all log lines with the following tags.
|
49
|
+
# config.log_tags = [ :subdomain, :uuid ]
|
50
|
+
|
51
|
+
# Use a different logger for distributed setups.
|
52
|
+
# config.logger = ActiveSupport::TaggedLogging.new(SyslogLogger.new)
|
53
|
+
|
54
|
+
# Use a different cache store in production.
|
55
|
+
# config.cache_store = :mem_cache_store
|
56
|
+
|
57
|
+
# Enable serving of images, stylesheets, and JavaScripts from an asset server.
|
58
|
+
# config.action_controller.asset_host = "http://assets.example.com"
|
59
|
+
|
60
|
+
# Precompile additional assets.
|
61
|
+
# application.js, application.css, and all non-JS/CSS in app/assets folder are already added.
|
62
|
+
# config.assets.precompile += %w( search.js )
|
63
|
+
|
64
|
+
# Ignore bad email addresses and do not raise email delivery errors.
|
65
|
+
# Set this to true and configure the email server for immediate delivery to raise delivery errors.
|
66
|
+
# config.action_mailer.raise_delivery_errors = false
|
67
|
+
|
68
|
+
# Enable locale fallbacks for I18n (makes lookups for any locale fall back to
|
69
|
+
# the I18n.default_locale when a translation can not be found).
|
70
|
+
config.i18n.fallbacks = true
|
71
|
+
|
72
|
+
# Send deprecation notices to registered listeners.
|
73
|
+
config.active_support.deprecation = :notify
|
74
|
+
|
75
|
+
# Disable automatic flushing of the log to improve performance.
|
76
|
+
# config.autoflush_log = false
|
77
|
+
|
78
|
+
# Use default logging formatter so that PID and timestamp are not suppressed.
|
79
|
+
config.log_formatter = ::Logger::Formatter.new
|
80
|
+
end
|
@@ -0,0 +1,36 @@
|
|
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_assets = 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
|
+
# Print deprecation notices to the stderr.
|
35
|
+
config.active_support.deprecation = :stderr
|
36
|
+
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,10 @@
|
|
1
|
+
# You can replace active_record with something else that is supported.
|
2
|
+
# This is the list of supported ORMs:
|
3
|
+
# - active_record
|
4
|
+
require 'custom_emails/orm/active_record'
|
5
|
+
|
6
|
+
# If emails are scoped to a certain model you should declare it with
|
7
|
+
# the `has_custom_emails` method and activate the association in the
|
8
|
+
# custom_emails with this option. (default: true)
|
9
|
+
#
|
10
|
+
# CustomEmails.scoped = false
|
@@ -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 = '8c92c28807a733ff100685c572d37de03bafa6e94ad7aabbbc69267dbe7bddf1476388895810a092f1b54a4972fcdd2a288941be30f15e95ee9f613838b077d3'
|
@@ -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
|
@@ -0,0 +1,23 @@
|
|
1
|
+
# Files in the config/locales directory are used for internationalization
|
2
|
+
# and are automatically loaded by Rails. If you want to use locales other
|
3
|
+
# than English, add the necessary files in this directory.
|
4
|
+
#
|
5
|
+
# To use the locales, use `I18n.t`:
|
6
|
+
#
|
7
|
+
# I18n.t 'hello'
|
8
|
+
#
|
9
|
+
# In views, this is aliased to just `t`:
|
10
|
+
#
|
11
|
+
# <%= t('hello') %>
|
12
|
+
#
|
13
|
+
# To use a different locale, set it with `I18n.locale`:
|
14
|
+
#
|
15
|
+
# I18n.locale = :es
|
16
|
+
#
|
17
|
+
# This would use the information in config/locales/es.yml.
|
18
|
+
#
|
19
|
+
# To learn more, please read the Rails Internationalization guide
|
20
|
+
# available at http://guides.rubyonrails.org/i18n.html.
|
21
|
+
|
22
|
+
en:
|
23
|
+
hello: "Hello world"
|
@@ -0,0 +1,56 @@
|
|
1
|
+
Dummy::Application.routes.draw do
|
2
|
+
# The priority is based upon order of creation: first created -> highest priority.
|
3
|
+
# See how all your routes lay out with "rake routes".
|
4
|
+
|
5
|
+
# You can have the root of your site routed with "root"
|
6
|
+
# root 'welcome#index'
|
7
|
+
|
8
|
+
# Example of regular route:
|
9
|
+
# get 'products/:id' => 'catalog#view'
|
10
|
+
|
11
|
+
# Example of named route that can be invoked with purchase_url(id: product.id)
|
12
|
+
# get 'products/:id/purchase' => 'catalog#purchase', as: :purchase
|
13
|
+
|
14
|
+
# Example resource route (maps HTTP verbs to controller actions automatically):
|
15
|
+
# resources :products
|
16
|
+
|
17
|
+
# Example resource route with options:
|
18
|
+
# resources :products do
|
19
|
+
# member do
|
20
|
+
# get 'short'
|
21
|
+
# post 'toggle'
|
22
|
+
# end
|
23
|
+
#
|
24
|
+
# collection do
|
25
|
+
# get 'sold'
|
26
|
+
# end
|
27
|
+
# end
|
28
|
+
|
29
|
+
# Example resource route with sub-resources:
|
30
|
+
# resources :products do
|
31
|
+
# resources :comments, :sales
|
32
|
+
# resource :seller
|
33
|
+
# end
|
34
|
+
|
35
|
+
# Example resource route with more complex sub-resources:
|
36
|
+
# resources :products do
|
37
|
+
# resources :comments
|
38
|
+
# resources :sales do
|
39
|
+
# get 'recent', on: :collection
|
40
|
+
# end
|
41
|
+
# end
|
42
|
+
|
43
|
+
# Example resource route with concerns:
|
44
|
+
# concern :toggleable do
|
45
|
+
# post 'toggle'
|
46
|
+
# end
|
47
|
+
# resources :posts, concerns: :toggleable
|
48
|
+
# resources :photos, concerns: :toggleable
|
49
|
+
|
50
|
+
# Example resource route within a namespace:
|
51
|
+
# namespace :admin do
|
52
|
+
# # Directs /admin/products/* to Admin::ProductsController
|
53
|
+
# # (app/controllers/admin/products_controller.rb)
|
54
|
+
# resources :products
|
55
|
+
# end
|
56
|
+
end
|
Binary file
|
@@ -0,0 +1,44 @@
|
|
1
|
+
# encoding: UTF-8
|
2
|
+
# This file is auto-generated from the current state of the database. Instead
|
3
|
+
# of editing this file, please use the migrations feature of Active Record to
|
4
|
+
# incrementally modify your database, and then regenerate this schema definition.
|
5
|
+
#
|
6
|
+
# Note that this schema.rb definition is the authoritative source for your
|
7
|
+
# database schema. If you need to create the application database on another
|
8
|
+
# system, you should be using db:schema:load, not running all the migrations
|
9
|
+
# from scratch. The latter is a flawed and unsustainable approach (the more migrations
|
10
|
+
# you'll amass, the slower it'll run and the greater likelihood for issues).
|
11
|
+
#
|
12
|
+
# It's strongly recommended that you check this file into your version control system.
|
13
|
+
|
14
|
+
ActiveRecord::Schema.define(version: 20131018164626) do
|
15
|
+
|
16
|
+
create_table "custom_emails_email_kinds", force: true do |t|
|
17
|
+
t.string "name"
|
18
|
+
t.datetime "created_at"
|
19
|
+
t.datetime "updated_at"
|
20
|
+
end
|
21
|
+
|
22
|
+
add_index "custom_emails_email_kinds", ["name"], name: "index_custom_emails_email_kinds_on_name", unique: true
|
23
|
+
|
24
|
+
create_table "custom_emails_emails", force: true do |t|
|
25
|
+
t.integer "emailable_id"
|
26
|
+
t.string "emailable_type"
|
27
|
+
t.string "locale"
|
28
|
+
t.text "subject"
|
29
|
+
t.text "content_text"
|
30
|
+
t.text "content_html"
|
31
|
+
t.datetime "created_at"
|
32
|
+
t.datetime "updated_at"
|
33
|
+
t.integer "kind_id"
|
34
|
+
end
|
35
|
+
|
36
|
+
add_index "custom_emails_emails", ["emailable_id"], name: "index_custom_emails_emails_on_emailable_id"
|
37
|
+
add_index "custom_emails_emails", ["kind_id", "emailable_id"], name: "index_custom_emails_emails_on_kind_id_and_emailable_id"
|
38
|
+
add_index "custom_emails_emails", ["kind_id", "locale", "emailable_id", "emailable_type"], name: "unique_w_kind_locale_and_emailable", unique: true
|
39
|
+
add_index "custom_emails_emails", ["locale"], name: "index_custom_emails_emails_on_locale"
|
40
|
+
|
41
|
+
create_table "examples", force: true do |t|
|
42
|
+
end
|
43
|
+
|
44
|
+
end
|
Binary file
|
@@ -0,0 +1,1201 @@
|
|
1
|
+
[1m[36m (140.8ms)[0m [1mCREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL) [0m
|
2
|
+
[1m[35m (59.7ms)[0m CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
|
3
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
4
|
+
Migrating to CreateCustomEmailsEmails (20131018141445)
|
5
|
+
[1m[35m (0.1ms)[0m begin transaction
|
6
|
+
[1m[36m (0.4ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime) [0m
|
7
|
+
[1m[35mSQL (0.7ms)[0m INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20131018141445"]]
|
8
|
+
[1m[36m (70.3ms)[0m [1mcommit transaction[0m
|
9
|
+
[1m[35mActiveRecord::SchemaMigration Load (0.1ms)[0m SELECT "schema_migrations".* FROM "schema_migrations"
|
10
|
+
[1m[36m (117.2ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime) [0m
|
11
|
+
[1m[35m (90.4ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
12
|
+
[1m[36m (60.2ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
13
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
14
|
+
[1m[36m (101.3ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
15
|
+
[1m[35m (0.3ms)[0m begin transaction
|
16
|
+
---------------------------------------
|
17
|
+
CustomEmails::EmailTest: test_the_truth
|
18
|
+
---------------------------------------
|
19
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
20
|
+
[1m[35m (0.0ms)[0m begin transaction
|
21
|
+
----------------------------
|
22
|
+
CustomEmailsTest: test_truth
|
23
|
+
----------------------------
|
24
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
25
|
+
[1m[36m (115.5ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime) [0m
|
26
|
+
[1m[35m (99.1ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
27
|
+
[1m[36m (60.2ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
28
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
29
|
+
[1m[36m (92.9ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
30
|
+
[1m[35m (0.2ms)[0m begin transaction
|
31
|
+
---------------------------------------------------------------------------------------
|
32
|
+
CustomEmails::EmailTest: test_email_needs_locale,_subject_and_content_text_to_be_valid?
|
33
|
+
---------------------------------------------------------------------------------------
|
34
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
35
|
+
[1m[35m (0.0ms)[0m begin transaction
|
36
|
+
----------------------------
|
37
|
+
CustomEmailsTest: test_truth
|
38
|
+
----------------------------
|
39
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
40
|
+
[1m[36m (87.4ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime) [0m
|
41
|
+
[1m[35m (90.7ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
42
|
+
[1m[36m (60.1ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
43
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
44
|
+
[1m[36m (109.6ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
45
|
+
[1m[35m (0.2ms)[0m begin transaction
|
46
|
+
---------------------------------------------------------------------------------------
|
47
|
+
CustomEmails::EmailTest: test_email_needs_locale,_subject_and_content_text_to_be_valid?
|
48
|
+
---------------------------------------------------------------------------------------
|
49
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
50
|
+
[1m[35m (0.0ms)[0m begin transaction
|
51
|
+
----------------------------
|
52
|
+
CustomEmailsTest: test_truth
|
53
|
+
----------------------------
|
54
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
55
|
+
[1m[36m (148.8ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime) [0m
|
56
|
+
[1m[35m (82.2ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
57
|
+
[1m[36m (60.1ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
58
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
59
|
+
[1m[36m (84.6ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
60
|
+
[1m[35m (0.2ms)[0m begin transaction
|
61
|
+
---------------------------------------------------------------------------------------
|
62
|
+
CustomEmails::EmailTest: test_email_needs_locale,_subject_and_content_text_to_be_valid?
|
63
|
+
---------------------------------------------------------------------------------------
|
64
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
65
|
+
[1m[35m (0.0ms)[0m begin transaction
|
66
|
+
----------------------------
|
67
|
+
CustomEmailsTest: test_truth
|
68
|
+
----------------------------
|
69
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
70
|
+
[1m[36m (98.4ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime) [0m
|
71
|
+
[1m[35m (89.8ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
72
|
+
[1m[36m (60.1ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
73
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
74
|
+
[1m[36m (68.0ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
75
|
+
[1m[35m (0.2ms)[0m begin transaction
|
76
|
+
---------------------------------------------------------------------------------------
|
77
|
+
CustomEmails::EmailTest: test_email_needs_locale,_subject_and_content_text_to_be_valid?
|
78
|
+
---------------------------------------------------------------------------------------
|
79
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
80
|
+
[1m[35m (0.0ms)[0m begin transaction
|
81
|
+
----------------------------
|
82
|
+
CustomEmailsTest: test_truth
|
83
|
+
----------------------------
|
84
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
85
|
+
[1m[36m (88.8ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime) [0m
|
86
|
+
[1m[35m (221.7ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
87
|
+
[1m[36m (60.1ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
88
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
89
|
+
[1m[36m (59.6ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
90
|
+
[1m[35m (0.2ms)[0m begin transaction
|
91
|
+
--------------------------------------------------------------------------------------
|
92
|
+
CustomEmails::EmailTest: test_email_needs_locale,_subject_and_content_text_to_be_valid
|
93
|
+
--------------------------------------------------------------------------------------
|
94
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
95
|
+
[1m[35m (0.0ms)[0m begin transaction
|
96
|
+
----------------------------
|
97
|
+
CustomEmailsTest: test_truth
|
98
|
+
----------------------------
|
99
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
100
|
+
[1m[36m (145.7ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime) [0m
|
101
|
+
[1m[35m (74.0ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
102
|
+
[1m[36m (60.1ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
103
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
104
|
+
[1m[36m (101.4ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
105
|
+
[1m[35m (0.2ms)[0m begin transaction
|
106
|
+
--------------------------------------------------------------------------------------
|
107
|
+
CustomEmails::EmailTest: test_email_needs_locale,_subject_and_content_text_to_be_valid
|
108
|
+
--------------------------------------------------------------------------------------
|
109
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
110
|
+
[1m[35m (0.0ms)[0m begin transaction
|
111
|
+
----------------------------
|
112
|
+
CustomEmailsTest: test_truth
|
113
|
+
----------------------------
|
114
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
115
|
+
[1m[36m (149.3ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime) [0m
|
116
|
+
[1m[35m (73.9ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
117
|
+
[1m[36m (60.1ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
118
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
119
|
+
[1m[36m (84.7ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
120
|
+
[1m[35m (0.2ms)[0m begin transaction
|
121
|
+
--------------------------------------------------------------------------------------
|
122
|
+
CustomEmails::EmailTest: test_email_needs_locale,_subject_and_content_text_to_be_valid
|
123
|
+
--------------------------------------------------------------------------------------
|
124
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
125
|
+
[1m[35m (0.0ms)[0m begin transaction
|
126
|
+
----------------------------
|
127
|
+
CustomEmailsTest: test_truth
|
128
|
+
----------------------------
|
129
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
130
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
131
|
+
[1m[35mActiveRecord::SchemaMigration Load (0.1ms)[0m SELECT "schema_migrations".* FROM "schema_migrations"
|
132
|
+
Migrating to CreateCustomEmailsEmails (20131018141445)
|
133
|
+
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
134
|
+
[1m[35m (0.0ms)[0m rollback transaction
|
135
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
136
|
+
[1m[35mActiveRecord::SchemaMigration Load (0.1ms)[0m SELECT "schema_migrations".* FROM "schema_migrations"
|
137
|
+
Migrating to CreateCustomEmailsEmails (20131018141445)
|
138
|
+
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
139
|
+
[1m[35m (0.2ms)[0m DROP TABLE "custom_emails_emails"
|
140
|
+
[1m[36mSQL (0.7ms)[0m [1mDELETE FROM "schema_migrations" WHERE "schema_migrations"."version" = '20131018141445'[0m
|
141
|
+
[1m[35m (93.9ms)[0m commit transaction
|
142
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
143
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
144
|
+
Migrating to CreateCustomEmailsEmails (20131018141445)
|
145
|
+
[1m[35m (0.0ms)[0m begin transaction
|
146
|
+
[1m[36m (0.3ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime) [0m
|
147
|
+
[1m[35m (0.1ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
148
|
+
[1m[36mSQL (0.6ms)[0m [1mINSERT INTO "schema_migrations" ("version") VALUES (?)[0m [["version", "20131018141445"]]
|
149
|
+
[1m[35m (80.7ms)[0m commit transaction
|
150
|
+
Migrating to CreateCustomEmailsEmailKinds (20131018143726)
|
151
|
+
[1m[36m (0.1ms)[0m [1mbegin transaction[0m
|
152
|
+
[1m[35m (0.3ms)[0m CREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime)
|
153
|
+
[1m[36m (0.3ms)[0m [1mCREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")[0m
|
154
|
+
[1m[35m (0.2ms)[0m ALTER TABLE "custom_emails_emails" ADD "kind_id" integer
|
155
|
+
[1m[36m (0.2ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
156
|
+
[1m[35mSQL (0.1ms)[0m INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20131018143726"]]
|
157
|
+
[1m[36m (71.9ms)[0m [1mcommit transaction[0m
|
158
|
+
[1m[35mActiveRecord::SchemaMigration Load (0.1ms)[0m SELECT "schema_migrations".* FROM "schema_migrations"
|
159
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
160
|
+
[1m[35mActiveRecord::SchemaMigration Load (0.1ms)[0m SELECT "schema_migrations".* FROM "schema_migrations"
|
161
|
+
Migrating to CreateCustomEmailsEmailKinds (20131018143726)
|
162
|
+
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
163
|
+
[1m[35m (0.2ms)[0m DROP INDEX "index_custom_emails_emails_on_kind_id"
|
164
|
+
[1m[36m (0.2ms)[0m [1mCREATE TEMPORARY TABLE "acustom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
165
|
+
[1m[35m (0.1ms)[0m CREATE INDEX "tindex_acustom_emails_emails_on_locale" ON "acustom_emails_emails" ("locale")
|
166
|
+
[1m[36m (0.0ms)[0m [1mSELECT * FROM "custom_emails_emails"[0m
|
167
|
+
[1m[35m (0.1ms)[0m DROP TABLE "custom_emails_emails"
|
168
|
+
[1m[36m (0.1ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime) [0m
|
169
|
+
[1m[35m (0.1ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
170
|
+
[1m[36m (0.0ms)[0m [1mSELECT * FROM "acustom_emails_emails"[0m
|
171
|
+
[1m[35m (0.1ms)[0m DROP TABLE "acustom_emails_emails"
|
172
|
+
[1m[36m (0.1ms)[0m [1mDROP INDEX "index_custom_emails_email_kinds_on_name"[0m
|
173
|
+
[1m[35m (0.1ms)[0m DROP TABLE "custom_emails_email_kinds"
|
174
|
+
[1m[36mSQL (0.6ms)[0m [1mDELETE FROM "schema_migrations" WHERE "schema_migrations"."version" = '20131018143726'[0m
|
175
|
+
[1m[35m (131.0ms)[0m commit transaction
|
176
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
177
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
178
|
+
[1m[35mActiveRecord::SchemaMigration Load (0.1ms)[0m SELECT "schema_migrations".* FROM "schema_migrations"
|
179
|
+
Migrating to CreateCustomEmailsEmails (20131018141445)
|
180
|
+
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
181
|
+
[1m[35m (0.2ms)[0m DROP INDEX "index_custom_emails_emails_on_locale"
|
182
|
+
[1m[36m (0.1ms)[0m [1mDROP TABLE "custom_emails_emails"[0m
|
183
|
+
[1m[35mSQL (0.6ms)[0m DELETE FROM "schema_migrations" WHERE "schema_migrations"."version" = '20131018141445'
|
184
|
+
[1m[36m (111.8ms)[0m [1mcommit transaction[0m
|
185
|
+
[1m[35mActiveRecord::SchemaMigration Load (0.1ms)[0m SELECT "schema_migrations".* FROM "schema_migrations"
|
186
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
187
|
+
[1m[35mActiveRecord::SchemaMigration Load (0.1ms)[0m SELECT "schema_migrations".* FROM "schema_migrations"
|
188
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
189
|
+
[1m[35mActiveRecord::SchemaMigration Load (0.0ms)[0m SELECT "schema_migrations".* FROM "schema_migrations"
|
190
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
191
|
+
Migrating to CreateCustomEmailsEmails (20131018141445)
|
192
|
+
[1m[35m (0.0ms)[0m begin transaction
|
193
|
+
[1m[36m (0.3ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime) [0m
|
194
|
+
[1m[35m (0.1ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
195
|
+
[1m[36m (0.1ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")[0m
|
196
|
+
[1m[35mSQL (0.7ms)[0m INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20131018141445"]]
|
197
|
+
[1m[36m (113.1ms)[0m [1mcommit transaction[0m
|
198
|
+
Migrating to CreateCustomEmailsEmailKinds (20131018143726)
|
199
|
+
[1m[35m (0.1ms)[0m begin transaction
|
200
|
+
[1m[36m (0.4ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
201
|
+
[1m[35m (0.3ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
202
|
+
[1m[36m (0.3ms)[0m [1mALTER TABLE "custom_emails_emails" ADD "kind_id" integer[0m
|
203
|
+
[1m[35m (0.2ms)[0m CREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")
|
204
|
+
[1m[36mSQL (0.2ms)[0m [1mINSERT INTO "schema_migrations" ("version") VALUES (?)[0m [["version", "20131018143726"]]
|
205
|
+
[1m[35m (88.1ms)[0m commit transaction
|
206
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
207
|
+
[1m[36m (99.6ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
208
|
+
[1m[35m (60.0ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
209
|
+
[1m[36m (59.6ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
210
|
+
[1m[35m (197.2ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
211
|
+
[1m[36m (73.7ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
212
|
+
[1m[35m (59.6ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
213
|
+
[1m[36m (94.9ms)[0m [1mCREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL) [0m
|
214
|
+
[1m[35m (59.9ms)[0m CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
|
215
|
+
[1m[36m (0.1ms)[0m [1mSELECT version FROM "schema_migrations"[0m
|
216
|
+
[1m[35m (68.1ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
217
|
+
[1m[36m (160.7ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
218
|
+
[1m[35m (0.2ms)[0m begin transaction
|
219
|
+
-------------------------------------------------------------------
|
220
|
+
CustomEmails::EmailTest: test_email_is_scoped_to_an_emailable_model
|
221
|
+
-------------------------------------------------------------------
|
222
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
223
|
+
[1m[35m (0.0ms)[0m begin transaction
|
224
|
+
--------------------------------------------------------------------------------------
|
225
|
+
CustomEmails::EmailTest: test_email_needs_locale,_subject_and_content_text_to_be_valid
|
226
|
+
--------------------------------------------------------------------------------------
|
227
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
228
|
+
[1m[35m (0.0ms)[0m begin transaction
|
229
|
+
----------------------------
|
230
|
+
CustomEmailsTest: test_truth
|
231
|
+
----------------------------
|
232
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
233
|
+
[1m[36m (132.4ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
234
|
+
[1m[35m (60.0ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
235
|
+
[1m[36m (59.6ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
236
|
+
[1m[35m (219.7ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
237
|
+
[1m[36m (93.5ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
238
|
+
[1m[35m (59.7ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
239
|
+
[1m[36m (94.2ms)[0m [1mCREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL) [0m
|
240
|
+
[1m[35m (59.9ms)[0m CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
|
241
|
+
[1m[36m (0.1ms)[0m [1mSELECT version FROM "schema_migrations"[0m
|
242
|
+
[1m[35m (68.1ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
243
|
+
[1m[36m (119.0ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
244
|
+
[1m[35m (0.2ms)[0m begin transaction
|
245
|
+
-------------------------------------------------------------------
|
246
|
+
CustomEmails::EmailTest: test_email_is_scoped_to_an_emailable_model
|
247
|
+
-------------------------------------------------------------------
|
248
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
249
|
+
[1m[35m (0.0ms)[0m begin transaction
|
250
|
+
--------------------------------------------------------------------------------------------
|
251
|
+
CustomEmails::EmailTest: test_email_needs_kind,_locale,_subject_and_content_text_to_be_valid
|
252
|
+
--------------------------------------------------------------------------------------------
|
253
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
254
|
+
[1m[35m (0.0ms)[0m begin transaction
|
255
|
+
----------------------------
|
256
|
+
CustomEmailsTest: test_truth
|
257
|
+
----------------------------
|
258
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
259
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
260
|
+
Migrating to CreateExamples (20131018164626)
|
261
|
+
[1m[35m (0.0ms)[0m begin transaction
|
262
|
+
[1m[36m (0.3ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
263
|
+
[1m[35mSQL (0.7ms)[0m INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20131018164626"]]
|
264
|
+
[1m[36m (116.9ms)[0m [1mcommit transaction[0m
|
265
|
+
[1m[35mActiveRecord::SchemaMigration Load (0.1ms)[0m SELECT "schema_migrations".* FROM "schema_migrations"
|
266
|
+
[1m[36m (87.7ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
267
|
+
[1m[35m (60.0ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
268
|
+
[1m[36m (59.6ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
269
|
+
[1m[35m (205.7ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
270
|
+
[1m[36m (65.1ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
271
|
+
[1m[35m (59.6ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
272
|
+
[1m[36m (68.1ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
273
|
+
[1m[35m (157.8ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
274
|
+
[1m[36m (60.3ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
275
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
276
|
+
[1m[36m (59.7ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018164626')[0m
|
277
|
+
[1m[35m (93.5ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
278
|
+
[1m[36m (126.8ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
279
|
+
[1m[35m (0.0ms)[0m begin transaction
|
280
|
+
----------------------------
|
281
|
+
CustomEmailsTest: test_truth
|
282
|
+
----------------------------
|
283
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
284
|
+
[1m[36m (121.5ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
285
|
+
[1m[35m (60.0ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
286
|
+
[1m[36m (59.7ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
287
|
+
[1m[35m (177.5ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
288
|
+
[1m[36m (60.2ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
289
|
+
[1m[35m (59.7ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
290
|
+
[1m[36m (68.1ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
291
|
+
[1m[35m (101.1ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
292
|
+
[1m[36m (60.2ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
293
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
294
|
+
[1m[36m (84.7ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018164626')[0m
|
295
|
+
[1m[35m (143.7ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
296
|
+
[1m[36m (60.3ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
297
|
+
[1m[35m (0.0ms)[0m begin transaction
|
298
|
+
----------------------------
|
299
|
+
CustomEmailsTest: test_truth
|
300
|
+
----------------------------
|
301
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
302
|
+
[1m[36m (100.1ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
303
|
+
[1m[35m (60.0ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
304
|
+
[1m[36m (59.7ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
305
|
+
[1m[35m (154.1ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
306
|
+
[1m[36m (75.1ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
307
|
+
[1m[35m (59.6ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
308
|
+
[1m[36m (68.1ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
309
|
+
[1m[35m (182.4ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
310
|
+
[1m[36m (60.4ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
311
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
312
|
+
[1m[36m (59.7ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018164626')[0m
|
313
|
+
[1m[35m (68.6ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
314
|
+
[1m[36m (135.5ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
315
|
+
[1m[35m (0.0ms)[0m begin transaction
|
316
|
+
----------------------------
|
317
|
+
CustomEmailsTest: test_truth
|
318
|
+
----------------------------
|
319
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
320
|
+
[1m[36m (103.9ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
321
|
+
[1m[35m (66.7ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
322
|
+
[1m[36m (59.8ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
323
|
+
[1m[35m (178.0ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
324
|
+
[1m[36m (68.0ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
325
|
+
[1m[35m (59.8ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
326
|
+
[1m[36m (76.2ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
327
|
+
[1m[35m (202.9ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
328
|
+
[1m[36m (68.7ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
329
|
+
[1m[35m (0.2ms)[0m SELECT version FROM "schema_migrations"
|
330
|
+
[1m[36m (218.3ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018164626')[0m
|
331
|
+
[1m[35m (60.3ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
332
|
+
[1m[36m (60.1ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
333
|
+
[1m[35m (0.1ms)[0m begin transaction
|
334
|
+
----------------------------
|
335
|
+
CustomEmailsTest: test_truth
|
336
|
+
----------------------------
|
337
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
338
|
+
[1m[36m (117.3ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
339
|
+
[1m[35m (60.0ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
340
|
+
[1m[36m (59.4ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
341
|
+
[1m[35m (173.8ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
342
|
+
[1m[36m (72.1ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
343
|
+
[1m[35m (59.7ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
344
|
+
[1m[36m (68.0ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
345
|
+
[1m[35m (174.3ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
346
|
+
[1m[36m (60.6ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
347
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
348
|
+
[1m[36m (59.9ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018164626')[0m
|
349
|
+
[1m[35m (169.6ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
350
|
+
[1m[36m (60.3ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
351
|
+
[1m[35m (0.0ms)[0m begin transaction
|
352
|
+
----------------------------
|
353
|
+
CustomEmailsTest: test_truth
|
354
|
+
----------------------------
|
355
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
356
|
+
[1m[36m (101.9ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
357
|
+
[1m[35m (60.1ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
358
|
+
[1m[36m (59.6ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
359
|
+
[1m[35m (169.0ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
360
|
+
[1m[36m (77.1ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
361
|
+
[1m[35m (59.6ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
362
|
+
[1m[36m (59.8ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
363
|
+
[1m[35m (199.1ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
364
|
+
[1m[36m (78.8ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
365
|
+
[1m[35m (0.2ms)[0m SELECT version FROM "schema_migrations"
|
366
|
+
[1m[36m (68.0ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018164626')[0m
|
367
|
+
[1m[35m (202.4ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
368
|
+
[1m[36m (60.3ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
369
|
+
[1m[35m (0.0ms)[0m begin transaction
|
370
|
+
----------------------------
|
371
|
+
CustomEmailsTest: test_truth
|
372
|
+
----------------------------
|
373
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
374
|
+
[1m[36m (95.9ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
375
|
+
[1m[35m (59.8ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
376
|
+
[1m[36m (143.8ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
377
|
+
[1m[35m (59.8ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
378
|
+
[1m[36m (60.2ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
379
|
+
[1m[35m (173.3ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
380
|
+
[1m[36m (80.2ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
381
|
+
[1m[35m (88.6ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
382
|
+
[1m[36m (60.3ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
383
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
384
|
+
[1m[36m (68.1ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018164626')[0m
|
385
|
+
[1m[35m (150.4ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
386
|
+
[1m[36m (185.1ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
387
|
+
[1m[35m (0.0ms)[0m begin transaction
|
388
|
+
----------------------------
|
389
|
+
CustomEmailsTest: test_truth
|
390
|
+
----------------------------
|
391
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
392
|
+
[1m[36m (97.2ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
393
|
+
[1m[35m (60.1ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
394
|
+
[1m[36m (59.7ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
395
|
+
[1m[35m (171.9ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
396
|
+
[1m[36m (73.7ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
397
|
+
[1m[35m (59.7ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
398
|
+
[1m[36m (59.7ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
399
|
+
[1m[35m (157.8ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
400
|
+
[1m[36m (60.2ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
401
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
402
|
+
[1m[36m (59.8ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018164626')[0m
|
403
|
+
[1m[35m (85.2ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
404
|
+
[1m[36m (110.2ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
405
|
+
[1m[35m (0.1ms)[0m begin transaction
|
406
|
+
----------------------------
|
407
|
+
CustomEmailsTest: test_truth
|
408
|
+
----------------------------
|
409
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
410
|
+
[1m[36m (108.3ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
411
|
+
[1m[35m (59.7ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
412
|
+
[1m[36m (59.6ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
413
|
+
[1m[35m (185.8ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
414
|
+
[1m[36m (60.4ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
415
|
+
[1m[35m (59.9ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
416
|
+
[1m[36m (68.1ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
417
|
+
[1m[35m (92.4ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
418
|
+
[1m[36m (60.1ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
419
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
420
|
+
[1m[36m (68.1ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018164626')[0m
|
421
|
+
[1m[35m (135.4ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
422
|
+
[1m[36m (60.4ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
423
|
+
[1m[35m (0.1ms)[0m begin transaction
|
424
|
+
----------------------------
|
425
|
+
CustomEmailsTest: test_truth
|
426
|
+
----------------------------
|
427
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
428
|
+
[1m[36m (91.1ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
429
|
+
[1m[35m (235.8ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
430
|
+
[1m[36m (59.8ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
431
|
+
[1m[35m (59.9ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
432
|
+
[1m[36m (76.7ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
433
|
+
[1m[35m (177.9ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
434
|
+
[1m[36m (59.6ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
435
|
+
[1m[35m (104.6ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
436
|
+
[1m[36m (60.3ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
437
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
438
|
+
[1m[36m (185.6ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018164626')[0m
|
439
|
+
[1m[35m (60.2ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
440
|
+
[1m[36m (60.2ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
441
|
+
[1m[35m (0.2ms)[0m begin transaction
|
442
|
+
-------------------------------------------------------------------
|
443
|
+
CustomEmails::EmailTest: test_email_is_scoped_to_an_emailable_model
|
444
|
+
-------------------------------------------------------------------
|
445
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
446
|
+
[1m[35m (0.0ms)[0m begin transaction
|
447
|
+
--------------------------------------------------------------------------------------------
|
448
|
+
CustomEmails::EmailTest: test_email_needs_kind,_locale,_subject_and_content_text_to_be_valid
|
449
|
+
--------------------------------------------------------------------------------------------
|
450
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
451
|
+
[1m[35m (0.0ms)[0m begin transaction
|
452
|
+
----------------------------
|
453
|
+
CustomEmailsTest: test_truth
|
454
|
+
----------------------------
|
455
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
456
|
+
[1m[35m (0.0ms)[0m begin transaction
|
457
|
+
------------------------------------------------------------------------------
|
458
|
+
ModelsTest: test_models_unsing_has_custom_emails_ends_with_an_:emails_relation
|
459
|
+
------------------------------------------------------------------------------
|
460
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
461
|
+
[1m[36m (85.8ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
462
|
+
[1m[35m (59.8ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
463
|
+
[1m[36m (59.6ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
464
|
+
[1m[35m (152.4ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
465
|
+
[1m[36m (60.1ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
466
|
+
[1m[35m (110.8ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
467
|
+
[1m[36m (118.0ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
468
|
+
[1m[35m (148.7ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
469
|
+
[1m[36m (60.2ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
470
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
471
|
+
[1m[36m (59.8ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018164626')[0m
|
472
|
+
[1m[35m (93.6ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
473
|
+
[1m[36m (126.8ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
474
|
+
[1m[35m (0.4ms)[0m begin transaction
|
475
|
+
-------------------------------------------------------------------
|
476
|
+
CustomEmails::EmailTest: test_email_is_scoped_to_an_emailable_model
|
477
|
+
-------------------------------------------------------------------
|
478
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
479
|
+
[1m[35m (0.0ms)[0m begin transaction
|
480
|
+
--------------------------------------------------------------------------------------------
|
481
|
+
CustomEmails::EmailTest: test_email_needs_kind,_locale,_subject_and_content_text_to_be_valid
|
482
|
+
--------------------------------------------------------------------------------------------
|
483
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
484
|
+
[1m[35m (0.0ms)[0m begin transaction
|
485
|
+
----------------------------
|
486
|
+
CustomEmailsTest: test_truth
|
487
|
+
----------------------------
|
488
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
489
|
+
[1m[35m (0.0ms)[0m begin transaction
|
490
|
+
------------------------------------------------------------------------------
|
491
|
+
ModelsTest: test_models_unsing_has_custom_emails_ends_with_an_:emails_relation
|
492
|
+
------------------------------------------------------------------------------
|
493
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
494
|
+
[1m[36m (115.7ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
495
|
+
[1m[35m (305.8ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
496
|
+
[1m[36m (59.4ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
497
|
+
[1m[35m (219.0ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
498
|
+
[1m[36m (59.9ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
499
|
+
[1m[35m (59.8ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
500
|
+
[1m[36m (84.6ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
501
|
+
[1m[35m (157.4ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
502
|
+
[1m[36m (60.5ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
503
|
+
[1m[35m (0.2ms)[0m SELECT version FROM "schema_migrations"
|
504
|
+
[1m[36m (59.7ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018164626')[0m
|
505
|
+
[1m[35m (185.9ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
506
|
+
[1m[36m (60.4ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
507
|
+
[1m[35m (0.4ms)[0m begin transaction
|
508
|
+
-------------------------------------------------------------------
|
509
|
+
CustomEmails::EmailTest: test_email_is_scoped_to_an_emailable_model
|
510
|
+
-------------------------------------------------------------------
|
511
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
512
|
+
[1m[35m (0.0ms)[0m begin transaction
|
513
|
+
--------------------------------------------------------------------------------------------
|
514
|
+
CustomEmails::EmailTest: test_email_needs_kind,_locale,_subject_and_content_text_to_be_valid
|
515
|
+
--------------------------------------------------------------------------------------------
|
516
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
517
|
+
[1m[35m (0.0ms)[0m begin transaction
|
518
|
+
----------------------------
|
519
|
+
CustomEmailsTest: test_truth
|
520
|
+
----------------------------
|
521
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
522
|
+
[1m[35m (0.0ms)[0m begin transaction
|
523
|
+
-------------------------------------------------------------------------------
|
524
|
+
MailerTest: test_email_content_text_is_used_when_send_custom_email_to_is_called
|
525
|
+
-------------------------------------------------------------------------------
|
526
|
+
[1m[36m (0.1ms)[0m [1mSAVEPOINT active_record_1[0m
|
527
|
+
[1m[35m (0.0ms)[0m ROLLBACK TO SAVEPOINT active_record_1
|
528
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
529
|
+
[1m[35m (0.0ms)[0m begin transaction
|
530
|
+
------------------------------------------------------------------------------
|
531
|
+
ModelsTest: test_models_unsing_has_custom_emails_ends_with_an_:emails_relation
|
532
|
+
------------------------------------------------------------------------------
|
533
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
534
|
+
[1m[36m (104.6ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
535
|
+
[1m[35m (59.8ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
536
|
+
[1m[36m (59.6ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
537
|
+
[1m[35m (160.7ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
538
|
+
[1m[36m (60.1ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
539
|
+
[1m[35m (59.7ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
540
|
+
[1m[36m (76.7ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
541
|
+
[1m[35m (141.0ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
542
|
+
[1m[36m (60.2ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
543
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
544
|
+
[1m[36m (59.6ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018164626')[0m
|
545
|
+
[1m[35m (85.3ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
546
|
+
[1m[36m (101.8ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
547
|
+
[1m[35m (0.2ms)[0m begin transaction
|
548
|
+
-------------------------------------------------------------------
|
549
|
+
CustomEmails::EmailTest: test_email_is_scoped_to_an_emailable_model
|
550
|
+
-------------------------------------------------------------------
|
551
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
552
|
+
[1m[35m (0.0ms)[0m begin transaction
|
553
|
+
--------------------------------------------------------------------------------------------
|
554
|
+
CustomEmails::EmailTest: test_email_needs_kind,_locale,_subject_and_content_text_to_be_valid
|
555
|
+
--------------------------------------------------------------------------------------------
|
556
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
557
|
+
[1m[35m (0.0ms)[0m begin transaction
|
558
|
+
----------------------------
|
559
|
+
CustomEmailsTest: test_truth
|
560
|
+
----------------------------
|
561
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
562
|
+
[1m[35m (0.0ms)[0m begin transaction
|
563
|
+
-------------------------------------------------------------------------------
|
564
|
+
MailerTest: test_email_content_text_is_used_when_send_custom_email_to_is_called
|
565
|
+
-------------------------------------------------------------------------------
|
566
|
+
[1m[36m (0.1ms)[0m [1mSAVEPOINT active_record_1[0m
|
567
|
+
[1m[35mCustomEmails::EmailKind Exists (0.2ms)[0m SELECT 1 AS one FROM "custom_emails_email_kinds" WHERE "custom_emails_email_kinds"."name" = 'kind_1' LIMIT 1
|
568
|
+
[1m[36mSQL (42.2ms)[0m [1mINSERT INTO "custom_emails_email_kinds" ("created_at", "name", "updated_at") VALUES (?, ?, ?)[0m [["created_at", Mon, 21 Oct 2013 10:33:30 UTC +00:00], ["name", :kind_1], ["updated_at", Mon, 21 Oct 2013 10:33:30 UTC +00:00]]
|
569
|
+
[1m[35m (0.1ms)[0m RELEASE SAVEPOINT active_record_1
|
570
|
+
[1m[36m (0.1ms)[0m [1mSAVEPOINT active_record_1[0m
|
571
|
+
[1m[35mSQL (0.2ms)[0m INSERT INTO "custom_emails_emails" ("content_text", "created_at", "kind_id", "locale", "subject", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["content_text", "Good luck..."], ["created_at", Mon, 21 Oct 2013 10:33:30 UTC +00:00], ["kind_id", 1], ["locale", :en], ["subject", "Hello wold!"], ["updated_at", Mon, 21 Oct 2013 10:33:30 UTC +00:00]]
|
572
|
+
[1m[36m (0.0ms)[0m [1mRELEASE SAVEPOINT active_record_1[0m
|
573
|
+
[1m[35mCustomEmails::EmailKind Load (0.1ms)[0m SELECT "custom_emails_email_kinds".* FROM "custom_emails_email_kinds" WHERE "custom_emails_email_kinds"."name" = 'kind_1' LIMIT 1
|
574
|
+
[1m[36mCustomEmails::Email Load (0.1ms)[0m [1mSELECT "custom_emails_emails".* FROM "custom_emails_emails" WHERE "custom_emails_emails"."kind_id" = 1 AND "custom_emails_emails"."emailable_id" IS NULL AND "custom_emails_emails"."locale" = 'en' LIMIT 1[0m
|
575
|
+
[1m[35m (0.1ms)[0m rollback transaction
|
576
|
+
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
577
|
+
------------------------------------------------------------------------------
|
578
|
+
ModelsTest: test_models_unsing_has_custom_emails_ends_with_an_:emails_relation
|
579
|
+
------------------------------------------------------------------------------
|
580
|
+
[1m[35m (0.0ms)[0m rollback transaction
|
581
|
+
[1m[36m (104.8ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
582
|
+
[1m[35m (59.7ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
583
|
+
[1m[36m (59.6ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
584
|
+
[1m[35m (109.8ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
585
|
+
[1m[36m (135.1ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
586
|
+
[1m[35m (59.9ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
587
|
+
[1m[36m (59.8ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
588
|
+
[1m[35m (166.6ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
589
|
+
[1m[36m (60.5ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
590
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
591
|
+
[1m[36m (59.7ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018164626')[0m
|
592
|
+
[1m[35m (169.3ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
593
|
+
[1m[36m (60.7ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
594
|
+
[1m[35m (0.2ms)[0m begin transaction
|
595
|
+
-------------------------------------------------------------------
|
596
|
+
CustomEmails::EmailTest: test_email_is_scoped_to_an_emailable_model
|
597
|
+
-------------------------------------------------------------------
|
598
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
599
|
+
[1m[35m (0.0ms)[0m begin transaction
|
600
|
+
--------------------------------------------------------------------------------------------
|
601
|
+
CustomEmails::EmailTest: test_email_needs_kind,_locale,_subject_and_content_text_to_be_valid
|
602
|
+
--------------------------------------------------------------------------------------------
|
603
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
604
|
+
[1m[35m (0.0ms)[0m begin transaction
|
605
|
+
----------------------------
|
606
|
+
CustomEmailsTest: test_truth
|
607
|
+
----------------------------
|
608
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
609
|
+
[1m[35m (0.0ms)[0m begin transaction
|
610
|
+
-------------------------------------------------------------------------------
|
611
|
+
MailerTest: test_email_content_text_is_used_when_send_custom_email_to_is_called
|
612
|
+
-------------------------------------------------------------------------------
|
613
|
+
[1m[36m (0.1ms)[0m [1mSAVEPOINT active_record_1[0m
|
614
|
+
[1m[35mCustomEmails::EmailKind Exists (0.1ms)[0m SELECT 1 AS one FROM "custom_emails_email_kinds" WHERE "custom_emails_email_kinds"."name" = 'kind_1' LIMIT 1
|
615
|
+
[1m[36mSQL (1.2ms)[0m [1mINSERT INTO "custom_emails_email_kinds" ("created_at", "name", "updated_at") VALUES (?, ?, ?)[0m [["created_at", Mon, 21 Oct 2013 10:33:51 UTC +00:00], ["name", :kind_1], ["updated_at", Mon, 21 Oct 2013 10:33:51 UTC +00:00]]
|
616
|
+
[1m[35m (0.0ms)[0m RELEASE SAVEPOINT active_record_1
|
617
|
+
[1m[36m (0.0ms)[0m [1mSAVEPOINT active_record_1[0m
|
618
|
+
[1m[35mSQL (0.2ms)[0m INSERT INTO "custom_emails_emails" ("content_text", "created_at", "kind_id", "locale", "subject", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["content_text", "Good luck..."], ["created_at", Mon, 21 Oct 2013 10:33:51 UTC +00:00], ["kind_id", 1], ["locale", :en], ["subject", "Hello wold!"], ["updated_at", Mon, 21 Oct 2013 10:33:51 UTC +00:00]]
|
619
|
+
[1m[36m (0.0ms)[0m [1mRELEASE SAVEPOINT active_record_1[0m
|
620
|
+
[1m[35mCustomEmails::EmailKind Load (0.1ms)[0m SELECT "custom_emails_email_kinds".* FROM "custom_emails_email_kinds" WHERE "custom_emails_email_kinds"."name" = 'kind_1' LIMIT 1
|
621
|
+
[1m[36mCustomEmails::Email Load (0.1ms)[0m [1mSELECT "custom_emails_emails".* FROM "custom_emails_emails" WHERE "custom_emails_emails"."kind_id" = 1 AND "custom_emails_emails"."emailable_id" IS NULL AND "custom_emails_emails"."locale" = 'en' LIMIT 1[0m
|
622
|
+
[1m[35m (0.1ms)[0m rollback transaction
|
623
|
+
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
624
|
+
------------------------------------------------------------------------------
|
625
|
+
ModelsTest: test_models_unsing_has_custom_emails_ends_with_an_:emails_relation
|
626
|
+
------------------------------------------------------------------------------
|
627
|
+
[1m[35m (0.0ms)[0m rollback transaction
|
628
|
+
[1m[36m (112.5ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
629
|
+
[1m[35m (59.9ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
630
|
+
[1m[36m (59.6ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
631
|
+
[1m[35m (178.2ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
632
|
+
[1m[36m (67.6ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
633
|
+
[1m[35m (59.5ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
634
|
+
[1m[36m (59.8ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
635
|
+
[1m[35m (141.1ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
636
|
+
[1m[36m (60.3ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
637
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
638
|
+
[1m[36m (59.7ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018164626')[0m
|
639
|
+
[1m[35m (93.5ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
640
|
+
[1m[36m (151.8ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
641
|
+
[1m[35m (0.2ms)[0m begin transaction
|
642
|
+
-------------------------------------------------------------------
|
643
|
+
CustomEmails::EmailTest: test_email_is_scoped_to_an_emailable_model
|
644
|
+
-------------------------------------------------------------------
|
645
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
646
|
+
[1m[35m (0.0ms)[0m begin transaction
|
647
|
+
--------------------------------------------------------------------------------------------
|
648
|
+
CustomEmails::EmailTest: test_email_needs_kind,_locale,_subject_and_content_text_to_be_valid
|
649
|
+
--------------------------------------------------------------------------------------------
|
650
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
651
|
+
[1m[35m (0.0ms)[0m begin transaction
|
652
|
+
----------------------------
|
653
|
+
CustomEmailsTest: test_truth
|
654
|
+
----------------------------
|
655
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
656
|
+
[1m[35m (0.0ms)[0m begin transaction
|
657
|
+
--------------------------------------------------------------------------
|
658
|
+
MailerTest: test_email_content_text_is_used_when_custom_email_to_is_called
|
659
|
+
--------------------------------------------------------------------------
|
660
|
+
[1m[36m (0.1ms)[0m [1mSAVEPOINT active_record_1[0m
|
661
|
+
[1m[35mCustomEmails::EmailKind Exists (0.1ms)[0m SELECT 1 AS one FROM "custom_emails_email_kinds" WHERE "custom_emails_email_kinds"."name" = 'kind_1' LIMIT 1
|
662
|
+
[1m[36mSQL (1.2ms)[0m [1mINSERT INTO "custom_emails_email_kinds" ("created_at", "name", "updated_at") VALUES (?, ?, ?)[0m [["created_at", Mon, 21 Oct 2013 10:34:43 UTC +00:00], ["name", :kind_1], ["updated_at", Mon, 21 Oct 2013 10:34:43 UTC +00:00]]
|
663
|
+
[1m[35m (0.0ms)[0m RELEASE SAVEPOINT active_record_1
|
664
|
+
[1m[36m (0.0ms)[0m [1mSAVEPOINT active_record_1[0m
|
665
|
+
[1m[35mSQL (0.2ms)[0m INSERT INTO "custom_emails_emails" ("content_text", "created_at", "kind_id", "locale", "subject", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["content_text", "Good luck..."], ["created_at", Mon, 21 Oct 2013 10:34:43 UTC +00:00], ["kind_id", 1], ["locale", :en], ["subject", "Hello wold!"], ["updated_at", Mon, 21 Oct 2013 10:34:43 UTC +00:00]]
|
666
|
+
[1m[36m (0.0ms)[0m [1mRELEASE SAVEPOINT active_record_1[0m
|
667
|
+
[1m[35mCustomEmails::EmailKind Load (0.1ms)[0m SELECT "custom_emails_email_kinds".* FROM "custom_emails_email_kinds" WHERE "custom_emails_email_kinds"."name" = 'kind_1' LIMIT 1
|
668
|
+
[1m[36mCustomEmails::Email Load (0.1ms)[0m [1mSELECT "custom_emails_emails".* FROM "custom_emails_emails" WHERE "custom_emails_emails"."kind_id" = 1 AND "custom_emails_emails"."emailable_id" IS NULL AND "custom_emails_emails"."locale" = 'en' LIMIT 1[0m
|
669
|
+
[1m[35m (0.1ms)[0m rollback transaction
|
670
|
+
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
671
|
+
------------------------------------------------------------------------------
|
672
|
+
ModelsTest: test_models_unsing_has_custom_emails_ends_with_an_:emails_relation
|
673
|
+
------------------------------------------------------------------------------
|
674
|
+
[1m[35m (0.0ms)[0m rollback transaction
|
675
|
+
[1m[36m (85.0ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
676
|
+
[1m[35m (59.9ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
677
|
+
[1m[36m (59.8ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
678
|
+
[1m[35m (169.1ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
679
|
+
[1m[36m (60.3ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
680
|
+
[1m[35m (59.7ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
681
|
+
[1m[36m (76.3ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
682
|
+
[1m[35m (124.0ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
683
|
+
[1m[36m (68.9ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
684
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
685
|
+
[1m[36m (166.4ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018164626')[0m
|
686
|
+
[1m[35m (60.1ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
687
|
+
[1m[36m (186.2ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
688
|
+
[1m[35m (0.2ms)[0m begin transaction
|
689
|
+
-------------------------------------------------------------------
|
690
|
+
CustomEmails::EmailTest: test_email_is_scoped_to_an_emailable_model
|
691
|
+
-------------------------------------------------------------------
|
692
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
693
|
+
[1m[35m (0.0ms)[0m begin transaction
|
694
|
+
--------------------------------------------------------------------------------------------
|
695
|
+
CustomEmails::EmailTest: test_email_needs_kind,_locale,_subject_and_content_text_to_be_valid
|
696
|
+
--------------------------------------------------------------------------------------------
|
697
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
698
|
+
[1m[35m (0.0ms)[0m begin transaction
|
699
|
+
----------------------------
|
700
|
+
CustomEmailsTest: test_truth
|
701
|
+
----------------------------
|
702
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
703
|
+
[1m[35m (0.0ms)[0m begin transaction
|
704
|
+
--------------------------------------------------------------------------
|
705
|
+
MailerTest: test_email_content_text_is_used_when_custom_email_to_is_called
|
706
|
+
--------------------------------------------------------------------------
|
707
|
+
[1m[36m (0.1ms)[0m [1mSAVEPOINT active_record_1[0m
|
708
|
+
[1m[35mCustomEmails::EmailKind Exists (0.1ms)[0m SELECT 1 AS one FROM "custom_emails_email_kinds" WHERE "custom_emails_email_kinds"."name" = 'kind_1' LIMIT 1
|
709
|
+
[1m[36mSQL (1.2ms)[0m [1mINSERT INTO "custom_emails_email_kinds" ("created_at", "name", "updated_at") VALUES (?, ?, ?)[0m [["created_at", Mon, 21 Oct 2013 10:35:09 UTC +00:00], ["name", :kind_1], ["updated_at", Mon, 21 Oct 2013 10:35:09 UTC +00:00]]
|
710
|
+
[1m[35m (0.0ms)[0m RELEASE SAVEPOINT active_record_1
|
711
|
+
[1m[36m (0.0ms)[0m [1mSAVEPOINT active_record_1[0m
|
712
|
+
[1m[35mSQL (0.2ms)[0m INSERT INTO "custom_emails_emails" ("content_text", "created_at", "kind_id", "locale", "subject", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["content_text", "Good luck..."], ["created_at", Mon, 21 Oct 2013 10:35:09 UTC +00:00], ["kind_id", 1], ["locale", :en], ["subject", "Hello wold!"], ["updated_at", Mon, 21 Oct 2013 10:35:09 UTC +00:00]]
|
713
|
+
[1m[36m (0.0ms)[0m [1mRELEASE SAVEPOINT active_record_1[0m
|
714
|
+
[1m[35mCustomEmails::EmailKind Load (0.1ms)[0m SELECT "custom_emails_email_kinds".* FROM "custom_emails_email_kinds" WHERE "custom_emails_email_kinds"."name" = 'kind_1' LIMIT 1
|
715
|
+
[1m[36mCustomEmails::Email Load (0.1ms)[0m [1mSELECT "custom_emails_emails".* FROM "custom_emails_emails" WHERE "custom_emails_emails"."kind_id" = 1 AND "custom_emails_emails"."emailable_id" IS NULL AND "custom_emails_emails"."locale" = 'en' LIMIT 1[0m
|
716
|
+
|
717
|
+
Sent mail to test@example.com (21.1ms)
|
718
|
+
Date: Mon, 21 Oct 2013 12:35:10 +0200
|
719
|
+
To: test@example.com
|
720
|
+
Message-ID: <5265035e936c_430510eb7fc2076f@chocapic.mail>
|
721
|
+
Subject: Hello wold!
|
722
|
+
Mime-Version: 1.0
|
723
|
+
Content-Type: text/plain;
|
724
|
+
charset=UTF-8
|
725
|
+
Content-Transfer-Encoding: 7bit
|
726
|
+
|
727
|
+
Good luck...
|
728
|
+
[1m[35m (0.2ms)[0m rollback transaction
|
729
|
+
[1m[36m (0.1ms)[0m [1mbegin transaction[0m
|
730
|
+
------------------------------------------------------------------------------
|
731
|
+
ModelsTest: test_models_unsing_has_custom_emails_ends_with_an_:emails_relation
|
732
|
+
------------------------------------------------------------------------------
|
733
|
+
[1m[35m (0.0ms)[0m rollback transaction
|
734
|
+
[1m[36m (113.3ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
735
|
+
[1m[35m (59.7ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
736
|
+
[1m[36m (59.6ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
737
|
+
[1m[35m (177.6ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
738
|
+
[1m[36m (68.6ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
739
|
+
[1m[35m (60.1ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
740
|
+
[1m[36m (67.8ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
741
|
+
[1m[35m (149.8ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
742
|
+
[1m[36m (60.2ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
743
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
744
|
+
[1m[36m (59.7ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018164626')[0m
|
745
|
+
[1m[35m (187.2ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
746
|
+
[1m[36m (60.1ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
747
|
+
[1m[35m (0.2ms)[0m begin transaction
|
748
|
+
-------------------------------------------------------------------
|
749
|
+
CustomEmails::EmailTest: test_email_is_scoped_to_an_emailable_model
|
750
|
+
-------------------------------------------------------------------
|
751
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
752
|
+
[1m[35m (0.0ms)[0m begin transaction
|
753
|
+
--------------------------------------------------------------------------------------------
|
754
|
+
CustomEmails::EmailTest: test_email_needs_kind,_locale,_subject_and_content_text_to_be_valid
|
755
|
+
--------------------------------------------------------------------------------------------
|
756
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
757
|
+
[1m[35m (0.0ms)[0m begin transaction
|
758
|
+
----------------------------
|
759
|
+
CustomEmailsTest: test_truth
|
760
|
+
----------------------------
|
761
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
762
|
+
[1m[35m (0.0ms)[0m begin transaction
|
763
|
+
--------------------------------------------------------------------------
|
764
|
+
MailerTest: test_email_content_text_is_used_when_custom_email_to_is_called
|
765
|
+
--------------------------------------------------------------------------
|
766
|
+
[1m[36m (0.1ms)[0m [1mSAVEPOINT active_record_1[0m
|
767
|
+
[1m[35mCustomEmails::EmailKind Exists (0.1ms)[0m SELECT 1 AS one FROM "custom_emails_email_kinds" WHERE "custom_emails_email_kinds"."name" = 'kind_1' LIMIT 1
|
768
|
+
[1m[36mSQL (1.2ms)[0m [1mINSERT INTO "custom_emails_email_kinds" ("created_at", "name", "updated_at") VALUES (?, ?, ?)[0m [["created_at", Mon, 21 Oct 2013 10:35:53 UTC +00:00], ["name", :kind_1], ["updated_at", Mon, 21 Oct 2013 10:35:53 UTC +00:00]]
|
769
|
+
[1m[35m (0.0ms)[0m RELEASE SAVEPOINT active_record_1
|
770
|
+
[1m[36m (0.0ms)[0m [1mSAVEPOINT active_record_1[0m
|
771
|
+
[1m[35mSQL (0.2ms)[0m INSERT INTO "custom_emails_emails" ("content_text", "created_at", "kind_id", "locale", "subject", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["content_text", "Good luck..."], ["created_at", Mon, 21 Oct 2013 10:35:53 UTC +00:00], ["kind_id", 1], ["locale", :en], ["subject", "Hello wold!"], ["updated_at", Mon, 21 Oct 2013 10:35:53 UTC +00:00]]
|
772
|
+
[1m[36m (0.0ms)[0m [1mRELEASE SAVEPOINT active_record_1[0m
|
773
|
+
[1m[35mCustomEmails::EmailKind Load (0.1ms)[0m SELECT "custom_emails_email_kinds".* FROM "custom_emails_email_kinds" WHERE "custom_emails_email_kinds"."name" = 'kind_1' LIMIT 1
|
774
|
+
[1m[36mCustomEmails::Email Load (0.1ms)[0m [1mSELECT "custom_emails_emails".* FROM "custom_emails_emails" WHERE "custom_emails_emails"."kind_id" = 1 AND "custom_emails_emails"."emailable_id" IS NULL AND "custom_emails_emails"."locale" = 'en' LIMIT 1[0m
|
775
|
+
|
776
|
+
Sent mail to test@example.com (4.2ms)
|
777
|
+
Date: Mon, 21 Oct 2013 12:35:53 +0200
|
778
|
+
To: test@example.com
|
779
|
+
Message-ID: <52650389c286e_43276637f8577ac@chocapic.mail>
|
780
|
+
Subject: Hello wold!
|
781
|
+
Mime-Version: 1.0
|
782
|
+
Content-Type: text/plain;
|
783
|
+
charset=UTF-8
|
784
|
+
Content-Transfer-Encoding: 7bit
|
785
|
+
|
786
|
+
Good luck...
|
787
|
+
[1m[35m (0.1ms)[0m rollback transaction
|
788
|
+
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
789
|
+
------------------------------------------------------------------------------
|
790
|
+
ModelsTest: test_models_unsing_has_custom_emails_ends_with_an_:emails_relation
|
791
|
+
------------------------------------------------------------------------------
|
792
|
+
[1m[35m (0.0ms)[0m rollback transaction
|
793
|
+
[1m[36m (89.9ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
794
|
+
[1m[35m (59.8ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
795
|
+
[1m[36m (59.6ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
796
|
+
[1m[35m (167.8ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
797
|
+
[1m[36m (70.0ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
798
|
+
[1m[35m (59.6ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
799
|
+
[1m[36m (67.9ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
800
|
+
[1m[35m (117.6ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
801
|
+
[1m[36m (60.5ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
802
|
+
[1m[35m (0.2ms)[0m SELECT version FROM "schema_migrations"
|
803
|
+
[1m[36m (59.8ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018164626')[0m
|
804
|
+
[1m[35m (93.5ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
805
|
+
[1m[36m (135.0ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
806
|
+
[1m[35m (0.2ms)[0m begin transaction
|
807
|
+
-------------------------------------------------------------------
|
808
|
+
CustomEmails::EmailTest: test_email_is_scoped_to_an_emailable_model
|
809
|
+
-------------------------------------------------------------------
|
810
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
811
|
+
[1m[35m (0.0ms)[0m begin transaction
|
812
|
+
--------------------------------------------------------------------------------------------
|
813
|
+
CustomEmails::EmailTest: test_email_needs_kind,_locale,_subject_and_content_text_to_be_valid
|
814
|
+
--------------------------------------------------------------------------------------------
|
815
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
816
|
+
[1m[35m (0.0ms)[0m begin transaction
|
817
|
+
----------------------------
|
818
|
+
CustomEmailsTest: test_truth
|
819
|
+
----------------------------
|
820
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
821
|
+
[1m[35m (0.0ms)[0m begin transaction
|
822
|
+
--------------------------------------------------------------------------
|
823
|
+
MailerTest: test_email_content_text_is_used_when_custom_email_to_is_called
|
824
|
+
--------------------------------------------------------------------------
|
825
|
+
[1m[36m (0.1ms)[0m [1mSAVEPOINT active_record_1[0m
|
826
|
+
[1m[35mCustomEmails::EmailKind Exists (0.1ms)[0m SELECT 1 AS one FROM "custom_emails_email_kinds" WHERE "custom_emails_email_kinds"."name" = 'kind_1' LIMIT 1
|
827
|
+
[1m[36mSQL (1.2ms)[0m [1mINSERT INTO "custom_emails_email_kinds" ("created_at", "name", "updated_at") VALUES (?, ?, ?)[0m [["created_at", Mon, 21 Oct 2013 10:38:33 UTC +00:00], ["name", :kind_1], ["updated_at", Mon, 21 Oct 2013 10:38:33 UTC +00:00]]
|
828
|
+
[1m[35m (0.0ms)[0m RELEASE SAVEPOINT active_record_1
|
829
|
+
[1m[36m (0.0ms)[0m [1mSAVEPOINT active_record_1[0m
|
830
|
+
[1m[35mSQL (0.2ms)[0m INSERT INTO "custom_emails_emails" ("content_text", "created_at", "kind_id", "locale", "subject", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["content_text", "Good luck..."], ["created_at", Mon, 21 Oct 2013 10:38:33 UTC +00:00], ["kind_id", 1], ["locale", :en], ["subject", "Hello wold!"], ["updated_at", Mon, 21 Oct 2013 10:38:33 UTC +00:00]]
|
831
|
+
[1m[36m (0.0ms)[0m [1mRELEASE SAVEPOINT active_record_1[0m
|
832
|
+
[1m[35mCustomEmails::EmailKind Load (0.1ms)[0m SELECT "custom_emails_email_kinds".* FROM "custom_emails_email_kinds" WHERE "custom_emails_email_kinds"."name" = 'kind_1' LIMIT 1
|
833
|
+
[1m[36mCustomEmails::Email Load (0.1ms)[0m [1mSELECT "custom_emails_emails".* FROM "custom_emails_emails" WHERE "custom_emails_emails"."kind_id" = 1 AND "custom_emails_emails"."emailable_id" IS NULL AND "custom_emails_emails"."locale" = 'en' LIMIT 1[0m
|
834
|
+
|
835
|
+
Sent mail to test@example.com (4.2ms)
|
836
|
+
Date: Mon, 21 Oct 2013 12:38:33 +0200
|
837
|
+
To: test@example.com
|
838
|
+
Message-ID: <52650429814d2_436dae2ff464953@chocapic.mail>
|
839
|
+
Subject: Hello wold!
|
840
|
+
Mime-Version: 1.0
|
841
|
+
Content-Type: text/plain;
|
842
|
+
charset=UTF-8
|
843
|
+
Content-Transfer-Encoding: 7bit
|
844
|
+
|
845
|
+
Good luck...
|
846
|
+
[1m[35m (0.1ms)[0m rollback transaction
|
847
|
+
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
848
|
+
------------------------------------------------------------------------------
|
849
|
+
ModelsTest: test_models_unsing_has_custom_emails_ends_with_an_:emails_relation
|
850
|
+
------------------------------------------------------------------------------
|
851
|
+
[1m[35m (0.0ms)[0m rollback transaction
|
852
|
+
[1m[36m (88.3ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
853
|
+
[1m[35m (60.0ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
854
|
+
[1m[36m (59.6ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
855
|
+
[1m[35m (169.2ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
856
|
+
[1m[36m (60.1ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
857
|
+
[1m[35m (60.2ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
858
|
+
[1m[36m (188.8ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
859
|
+
[1m[35m (62.8ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
860
|
+
[1m[36m (60.2ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
861
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
862
|
+
[1m[36m (68.1ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018164626')[0m
|
863
|
+
[1m[35m (169.1ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
864
|
+
[1m[36m (60.3ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
865
|
+
[1m[35m (0.2ms)[0m begin transaction
|
866
|
+
-------------------------------------------------------------------
|
867
|
+
CustomEmails::EmailTest: test_email_is_scoped_to_an_emailable_model
|
868
|
+
-------------------------------------------------------------------
|
869
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
870
|
+
[1m[35m (0.0ms)[0m begin transaction
|
871
|
+
--------------------------------------------------------------------------------------------
|
872
|
+
CustomEmails::EmailTest: test_email_needs_kind,_locale,_subject_and_content_text_to_be_valid
|
873
|
+
--------------------------------------------------------------------------------------------
|
874
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
875
|
+
[1m[35m (0.0ms)[0m begin transaction
|
876
|
+
----------------------------
|
877
|
+
CustomEmailsTest: test_truth
|
878
|
+
----------------------------
|
879
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
880
|
+
[1m[35m (0.0ms)[0m begin transaction
|
881
|
+
--------------------------------------------------------------------------
|
882
|
+
MailerTest: test_email_content_text_is_used_when_custom_email_to_is_called
|
883
|
+
--------------------------------------------------------------------------
|
884
|
+
[1m[36m (0.1ms)[0m [1mSAVEPOINT active_record_1[0m
|
885
|
+
[1m[35mCustomEmails::EmailKind Exists (0.1ms)[0m SELECT 1 AS one FROM "custom_emails_email_kinds" WHERE "custom_emails_email_kinds"."name" = 'kind_1' LIMIT 1
|
886
|
+
[1m[36mSQL (1.2ms)[0m [1mINSERT INTO "custom_emails_email_kinds" ("created_at", "name", "updated_at") VALUES (?, ?, ?)[0m [["created_at", Mon, 21 Oct 2013 10:52:31 UTC +00:00], ["name", :kind_1], ["updated_at", Mon, 21 Oct 2013 10:52:31 UTC +00:00]]
|
887
|
+
[1m[35m (0.0ms)[0m RELEASE SAVEPOINT active_record_1
|
888
|
+
[1m[36m (0.0ms)[0m [1mSAVEPOINT active_record_1[0m
|
889
|
+
[1m[35mSQL (0.2ms)[0m INSERT INTO "custom_emails_emails" ("content_text", "created_at", "kind_id", "locale", "subject", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["content_text", "Good luck..."], ["created_at", Mon, 21 Oct 2013 10:52:31 UTC +00:00], ["kind_id", 1], ["locale", :en], ["subject", "Hello wold!"], ["updated_at", Mon, 21 Oct 2013 10:52:31 UTC +00:00]]
|
890
|
+
[1m[36m (0.0ms)[0m [1mRELEASE SAVEPOINT active_record_1[0m
|
891
|
+
[1m[35mCustomEmails::EmailKind Load (0.1ms)[0m SELECT "custom_emails_email_kinds".* FROM "custom_emails_email_kinds" WHERE "custom_emails_email_kinds"."name" = 'kind_1' LIMIT 1
|
892
|
+
[1m[36mCustomEmails::Email Load (0.1ms)[0m [1mSELECT "custom_emails_emails".* FROM "custom_emails_emails" WHERE "custom_emails_emails"."kind_id" = 1 AND "custom_emails_emails"."emailable_id" IS NULL AND "custom_emails_emails"."locale" = 'en' LIMIT 1[0m
|
893
|
+
|
894
|
+
Sent mail to test@example.com (4.3ms)
|
895
|
+
Date: Mon, 21 Oct 2013 12:52:31 +0200
|
896
|
+
To: test@example.com
|
897
|
+
Message-ID: <5265076fbf3c8_443d6dd800624aa@chocapic.mail>
|
898
|
+
Subject: Hello wold!
|
899
|
+
Mime-Version: 1.0
|
900
|
+
Content-Type: text/plain;
|
901
|
+
charset=UTF-8
|
902
|
+
Content-Transfer-Encoding: 7bit
|
903
|
+
|
904
|
+
Good luck...
|
905
|
+
[1m[35m (0.1ms)[0m rollback transaction
|
906
|
+
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
907
|
+
------------------------------------------------------------------------------
|
908
|
+
ModelsTest: test_models_unsing_has_custom_emails_ends_with_an_:emails_relation
|
909
|
+
------------------------------------------------------------------------------
|
910
|
+
[1m[35m (0.0ms)[0m rollback transaction
|
911
|
+
[1m[36m (133.8ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
912
|
+
[1m[35m (185.1ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
913
|
+
[1m[36m (84.4ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
914
|
+
[1m[35m (59.8ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
915
|
+
[1m[36m (144.7ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
916
|
+
[1m[35m (59.7ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
917
|
+
[1m[36m (59.6ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
918
|
+
[1m[35m (94.3ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
919
|
+
[1m[36m (60.2ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
920
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
921
|
+
[1m[36m (68.0ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018164626')[0m
|
922
|
+
[1m[35m (160.4ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
923
|
+
[1m[36m (60.5ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
924
|
+
[1m[35m (0.2ms)[0m begin transaction
|
925
|
+
-------------------------------------------------------------------
|
926
|
+
CustomEmails::EmailTest: test_email_is_scoped_to_an_emailable_model
|
927
|
+
-------------------------------------------------------------------
|
928
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
929
|
+
[1m[35m (0.0ms)[0m begin transaction
|
930
|
+
--------------------------------------------------------------------------------------------
|
931
|
+
CustomEmails::EmailTest: test_email_needs_kind,_locale,_subject_and_content_text_to_be_valid
|
932
|
+
--------------------------------------------------------------------------------------------
|
933
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
934
|
+
[1m[35m (0.0ms)[0m begin transaction
|
935
|
+
----------------------------
|
936
|
+
CustomEmailsTest: test_truth
|
937
|
+
----------------------------
|
938
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
939
|
+
[1m[35m (0.0ms)[0m begin transaction
|
940
|
+
--------------------------------------------------------------------------
|
941
|
+
MailerTest: test_email_content_text_is_used_when_custom_email_to_is_called
|
942
|
+
--------------------------------------------------------------------------
|
943
|
+
[1m[36m (0.1ms)[0m [1mSAVEPOINT active_record_1[0m
|
944
|
+
[1m[35mCustomEmails::EmailKind Exists (0.1ms)[0m SELECT 1 AS one FROM "custom_emails_email_kinds" WHERE "custom_emails_email_kinds"."name" = 'kind_1' LIMIT 1
|
945
|
+
[1m[36mSQL (1.2ms)[0m [1mINSERT INTO "custom_emails_email_kinds" ("created_at", "name", "updated_at") VALUES (?, ?, ?)[0m [["created_at", Mon, 21 Oct 2013 10:54:19 UTC +00:00], ["name", :kind_1], ["updated_at", Mon, 21 Oct 2013 10:54:19 UTC +00:00]]
|
946
|
+
[1m[35m (0.0ms)[0m RELEASE SAVEPOINT active_record_1
|
947
|
+
[1m[36m (0.0ms)[0m [1mSAVEPOINT active_record_1[0m
|
948
|
+
[1m[35mSQL (0.2ms)[0m INSERT INTO "custom_emails_emails" ("content_text", "created_at", "kind_id", "locale", "subject", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["content_text", "Good luck..."], ["created_at", Mon, 21 Oct 2013 10:54:19 UTC +00:00], ["kind_id", 1], ["locale", :en], ["subject", "Hello wold!"], ["updated_at", Mon, 21 Oct 2013 10:54:19 UTC +00:00]]
|
949
|
+
[1m[36m (0.0ms)[0m [1mRELEASE SAVEPOINT active_record_1[0m
|
950
|
+
[1m[35mCustomEmails::EmailKind Load (0.1ms)[0m SELECT "custom_emails_email_kinds".* FROM "custom_emails_email_kinds" WHERE "custom_emails_email_kinds"."name" = 'kind_1' LIMIT 1
|
951
|
+
[1m[36mCustomEmails::Email Load (0.1ms)[0m [1mSELECT "custom_emails_emails".* FROM "custom_emails_emails" WHERE "custom_emails_emails"."kind_id" = 1 AND "custom_emails_emails"."emailable_id" IS NULL AND "custom_emails_emails"."locale" = 'en' LIMIT 1[0m
|
952
|
+
|
953
|
+
Sent mail to test@example.com (4.3ms)
|
954
|
+
Date: Mon, 21 Oct 2013 12:54:19 +0200
|
955
|
+
To: test@example.com
|
956
|
+
Message-ID: <526507db8ba5b_44d75a57f825039@chocapic.mail>
|
957
|
+
Subject: Hello wold!
|
958
|
+
Mime-Version: 1.0
|
959
|
+
Content-Type: text/plain;
|
960
|
+
charset=UTF-8
|
961
|
+
Content-Transfer-Encoding: 7bit
|
962
|
+
|
963
|
+
Good luck...
|
964
|
+
[1m[35m (0.1ms)[0m rollback transaction
|
965
|
+
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
966
|
+
------------------------------------------------------------------------------
|
967
|
+
ModelsTest: test_models_unsing_has_custom_emails_ends_with_an_:emails_relation
|
968
|
+
------------------------------------------------------------------------------
|
969
|
+
[1m[35m (0.0ms)[0m rollback transaction
|
970
|
+
[1m[36m (109.8ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
971
|
+
[1m[35m (59.9ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
972
|
+
[1m[36m (59.7ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
973
|
+
[1m[35m (152.5ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
974
|
+
[1m[36m (60.0ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
975
|
+
[1m[35m (59.9ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
976
|
+
[1m[36m (67.9ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
977
|
+
[1m[35m (140.9ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
978
|
+
[1m[36m (60.3ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
979
|
+
[1m[35m (0.1ms)[0m SELECT version FROM "schema_migrations"
|
980
|
+
[1m[36m (59.8ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018164626')[0m
|
981
|
+
[1m[35m (93.4ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
982
|
+
[1m[36m (135.0ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
983
|
+
[1m[35m (0.2ms)[0m begin transaction
|
984
|
+
-------------------------------------------------------------------
|
985
|
+
CustomEmails::EmailTest: test_email_is_scoped_to_an_emailable_model
|
986
|
+
-------------------------------------------------------------------
|
987
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
988
|
+
[1m[35m (0.0ms)[0m begin transaction
|
989
|
+
--------------------------------------------------------------------------------------------
|
990
|
+
CustomEmails::EmailTest: test_email_needs_kind,_locale,_subject_and_content_text_to_be_valid
|
991
|
+
--------------------------------------------------------------------------------------------
|
992
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
993
|
+
[1m[35m (0.0ms)[0m begin transaction
|
994
|
+
----------------------------
|
995
|
+
CustomEmailsTest: test_truth
|
996
|
+
----------------------------
|
997
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
998
|
+
[1m[35m (0.0ms)[0m begin transaction
|
999
|
+
--------------------------------------------------------------------------
|
1000
|
+
MailerTest: test_email_content_text_is_used_when_custom_email_to_is_called
|
1001
|
+
--------------------------------------------------------------------------
|
1002
|
+
[1m[36m (0.1ms)[0m [1mSAVEPOINT active_record_1[0m
|
1003
|
+
[1m[35mCustomEmails::EmailKind Exists (0.1ms)[0m SELECT 1 AS one FROM "custom_emails_email_kinds" WHERE "custom_emails_email_kinds"."name" = 'kind_1' LIMIT 1
|
1004
|
+
[1m[36mSQL (1.5ms)[0m [1mINSERT INTO "custom_emails_email_kinds" ("created_at", "name", "updated_at") VALUES (?, ?, ?)[0m [["created_at", Mon, 21 Oct 2013 10:54:45 UTC +00:00], ["name", :kind_1], ["updated_at", Mon, 21 Oct 2013 10:54:45 UTC +00:00]]
|
1005
|
+
[1m[35m (0.0ms)[0m RELEASE SAVEPOINT active_record_1
|
1006
|
+
[1m[36m (0.0ms)[0m [1mSAVEPOINT active_record_1[0m
|
1007
|
+
[1m[35mSQL (0.2ms)[0m INSERT INTO "custom_emails_emails" ("content_text", "created_at", "kind_id", "locale", "subject", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["content_text", "Good luck..."], ["created_at", Mon, 21 Oct 2013 10:54:45 UTC +00:00], ["kind_id", 1], ["locale", :en], ["subject", "Hello wold!"], ["updated_at", Mon, 21 Oct 2013 10:54:45 UTC +00:00]]
|
1008
|
+
[1m[36m (0.0ms)[0m [1mRELEASE SAVEPOINT active_record_1[0m
|
1009
|
+
[1m[35mCustomEmails::EmailKind Load (0.1ms)[0m SELECT "custom_emails_email_kinds".* FROM "custom_emails_email_kinds" WHERE "custom_emails_email_kinds"."name" = 'kind_1' LIMIT 1
|
1010
|
+
[1m[36mCustomEmails::Email Load (0.1ms)[0m [1mSELECT "custom_emails_emails".* FROM "custom_emails_emails" WHERE "custom_emails_emails"."kind_id" = 1 AND "custom_emails_emails"."emailable_id" IS NULL AND "custom_emails_emails"."locale" = 'en' LIMIT 1[0m
|
1011
|
+
|
1012
|
+
Sent mail to test@example.com (4.3ms)
|
1013
|
+
Date: Mon, 21 Oct 2013 12:54:45 +0200
|
1014
|
+
To: test@example.com
|
1015
|
+
Message-ID: <526507f5e6709_450a12b57f459563@chocapic.mail>
|
1016
|
+
Subject: Hello wold!
|
1017
|
+
Mime-Version: 1.0
|
1018
|
+
Content-Type: text/plain;
|
1019
|
+
charset=UTF-8
|
1020
|
+
Content-Transfer-Encoding: 7bit
|
1021
|
+
|
1022
|
+
Good luck...
|
1023
|
+
[1m[35m (0.1ms)[0m rollback transaction
|
1024
|
+
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
1025
|
+
------------------------------------------------------------------------------
|
1026
|
+
ModelsTest: test_models_unsing_has_custom_emails_ends_with_an_:emails_relation
|
1027
|
+
------------------------------------------------------------------------------
|
1028
|
+
[1m[35m (0.1ms)[0m rollback transaction
|
1029
|
+
[1m[36m (142.0ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
1030
|
+
[1m[35m (59.7ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
1031
|
+
[1m[36m (59.4ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
1032
|
+
[1m[35m (109.8ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
1033
|
+
[1m[36m (168.0ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_kind_id" ON "custom_emails_emails" ("kind_id")[0m
|
1034
|
+
[1m[35m (59.8ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
1035
|
+
[1m[36m (59.6ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
1036
|
+
[1m[35m (82.6ms)[0m CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
|
1037
|
+
[1m[36m (152.0ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
1038
|
+
[1m[35m (0.2ms)[0m SELECT version FROM "schema_migrations"
|
1039
|
+
[1m[36m (59.6ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018164626')[0m
|
1040
|
+
[1m[35m (60.0ms)[0m INSERT INTO "schema_migrations" (version) VALUES ('20131018143726')
|
1041
|
+
[1m[36m (85.2ms)[0m [1mINSERT INTO "schema_migrations" (version) VALUES ('20131018141445')[0m
|
1042
|
+
[1m[35m (0.2ms)[0m begin transaction
|
1043
|
+
-------------------------------------------------------------------
|
1044
|
+
CustomEmails::EmailTest: test_email_is_scoped_to_an_emailable_model
|
1045
|
+
-------------------------------------------------------------------
|
1046
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
1047
|
+
[1m[35m (0.0ms)[0m begin transaction
|
1048
|
+
--------------------------------------------------------------------------------------------
|
1049
|
+
CustomEmails::EmailTest: test_email_needs_kind,_locale,_subject_and_content_text_to_be_valid
|
1050
|
+
--------------------------------------------------------------------------------------------
|
1051
|
+
[1m[36m (0.1ms)[0m [1mrollback transaction[0m
|
1052
|
+
[1m[35m (0.0ms)[0m begin transaction
|
1053
|
+
----------------------------
|
1054
|
+
CustomEmailsTest: test_truth
|
1055
|
+
----------------------------
|
1056
|
+
[1m[36m (0.0ms)[0m [1mrollback transaction[0m
|
1057
|
+
[1m[35m (0.0ms)[0m begin transaction
|
1058
|
+
--------------------------------------------------------------------------
|
1059
|
+
MailerTest: test_email_content_text_is_used_when_custom_email_to_is_called
|
1060
|
+
--------------------------------------------------------------------------
|
1061
|
+
[1m[36m (0.1ms)[0m [1mSAVEPOINT active_record_1[0m
|
1062
|
+
[1m[35mCustomEmails::EmailKind Exists (0.1ms)[0m SELECT 1 AS one FROM "custom_emails_email_kinds" WHERE "custom_emails_email_kinds"."name" = 'kind_1' LIMIT 1
|
1063
|
+
[1m[36mSQL (1.7ms)[0m [1mINSERT INTO "custom_emails_email_kinds" ("created_at", "name", "updated_at") VALUES (?, ?, ?)[0m [["created_at", Mon, 21 Oct 2013 11:26:20 UTC +00:00], ["name", :kind_1], ["updated_at", Mon, 21 Oct 2013 11:26:20 UTC +00:00]]
|
1064
|
+
[1m[35m (0.1ms)[0m RELEASE SAVEPOINT active_record_1
|
1065
|
+
[1m[36m (0.0ms)[0m [1mSAVEPOINT active_record_1[0m
|
1066
|
+
[1m[35mSQL (0.3ms)[0m INSERT INTO "custom_emails_emails" ("content_text", "created_at", "kind_id", "locale", "subject", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["content_text", "Good luck..."], ["created_at", Mon, 21 Oct 2013 11:26:20 UTC +00:00], ["kind_id", 1], ["locale", :en], ["subject", "Hello wold!"], ["updated_at", Mon, 21 Oct 2013 11:26:20 UTC +00:00]]
|
1067
|
+
[1m[36m (0.0ms)[0m [1mRELEASE SAVEPOINT active_record_1[0m
|
1068
|
+
[1m[35mCustomEmails::EmailKind Load (0.1ms)[0m SELECT "custom_emails_email_kinds".* FROM "custom_emails_email_kinds" WHERE "custom_emails_email_kinds"."name" = 'kind_1' LIMIT 1
|
1069
|
+
[1m[36mCustomEmails::Email Load (0.1ms)[0m [1mSELECT "custom_emails_emails".* FROM "custom_emails_emails" WHERE "custom_emails_emails"."kind_id" = 1 AND "custom_emails_emails"."emailable_id" IS NULL AND "custom_emails_emails"."locale" = 'en' LIMIT 1[0m
|
1070
|
+
|
1071
|
+
Sent mail to test@example.com (20.5ms)
|
1072
|
+
Date: Mon, 21 Oct 2013 13:26:20 +0200
|
1073
|
+
To: test@example.com
|
1074
|
+
Message-ID: <52650f5c2170f_47944a27fc919ee@chocapic.mail>
|
1075
|
+
Subject: Hello wold!
|
1076
|
+
Mime-Version: 1.0
|
1077
|
+
Content-Type: text/plain;
|
1078
|
+
charset=UTF-8
|
1079
|
+
Content-Transfer-Encoding: 7bit
|
1080
|
+
|
1081
|
+
Good luck...
|
1082
|
+
|
1083
|
+
Sent mail to test@example.com (21.1ms)
|
1084
|
+
Date: Mon, 21 Oct 2013 13:26:20 +0200
|
1085
|
+
To: test@example.com
|
1086
|
+
Message-ID: <52650f5c2170f_47944a27fc919ee@chocapic.mail>
|
1087
|
+
Subject: Hello wold!
|
1088
|
+
Mime-Version: 1.0
|
1089
|
+
Content-Type: text/plain;
|
1090
|
+
charset=UTF-8
|
1091
|
+
Content-Transfer-Encoding: 7bit
|
1092
|
+
|
1093
|
+
Good luck...
|
1094
|
+
|
1095
|
+
Sent mail to test@example.com (2.2ms)
|
1096
|
+
Date: Mon, 21 Oct 2013 13:26:20 +0200
|
1097
|
+
To: test@example.com
|
1098
|
+
Message-ID: <52650f5c2170f_47944a27fc919ee@chocapic.mail>
|
1099
|
+
Subject: Hello wold!
|
1100
|
+
Mime-Version: 1.0
|
1101
|
+
Content-Type: text/plain;
|
1102
|
+
charset=UTF-8
|
1103
|
+
Content-Transfer-Encoding: 7bit
|
1104
|
+
|
1105
|
+
Good luck...
|
1106
|
+
[1m[35m (0.3ms)[0m rollback transaction
|
1107
|
+
[1m[36m (0.1ms)[0m [1mbegin transaction[0m
|
1108
|
+
------------------------------------------------------------------------------
|
1109
|
+
ModelsTest: test_models_unsing_has_custom_emails_ends_with_an_:emails_relation
|
1110
|
+
------------------------------------------------------------------------------
|
1111
|
+
[1m[35m (0.1ms)[0m rollback transaction
|
1112
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
1113
|
+
[1m[35mActiveRecord::SchemaMigration Load (0.1ms)[0m SELECT "schema_migrations".* FROM "schema_migrations"
|
1114
|
+
Migrating to CreateExamples (20131018164626)
|
1115
|
+
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
1116
|
+
[1m[35m (0.5ms)[0m DROP TABLE "examples"
|
1117
|
+
[1m[36mSQL (1.3ms)[0m [1mDELETE FROM "schema_migrations" WHERE "schema_migrations"."version" = '20131018164626'[0m
|
1118
|
+
[1m[35m (103.0ms)[0m commit transaction
|
1119
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
1120
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
1121
|
+
[1m[35mActiveRecord::SchemaMigration Load (0.1ms)[0m SELECT "schema_migrations".* FROM "schema_migrations"
|
1122
|
+
Migrating to CreateCustomEmailsEmailKinds (20131018143726)
|
1123
|
+
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
1124
|
+
[1m[35m (0.2ms)[0m DROP INDEX "index_custom_emails_emails_on_kind_id"
|
1125
|
+
[1m[36m (0.2ms)[0m [1mCREATE TEMPORARY TABLE "acustom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime, "kind_id" integer) [0m
|
1126
|
+
[1m[35m (0.1ms)[0m CREATE INDEX "tindex_acustom_emails_emails_on_emailable_id" ON "acustom_emails_emails" ("emailable_id")
|
1127
|
+
[1m[36m (0.1ms)[0m [1mCREATE INDEX "tindex_acustom_emails_emails_on_locale" ON "acustom_emails_emails" ("locale")[0m
|
1128
|
+
[1m[35m (0.1ms)[0m SELECT * FROM "custom_emails_emails"
|
1129
|
+
[1m[36m (0.2ms)[0m [1mDROP TABLE "custom_emails_emails"[0m
|
1130
|
+
[1m[35m (0.1ms)[0m CREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime)
|
1131
|
+
[1m[36m (0.1ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")[0m
|
1132
|
+
[1m[35m (0.1ms)[0m CREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")
|
1133
|
+
[1m[36m (0.1ms)[0m [1mSELECT * FROM "acustom_emails_emails"[0m
|
1134
|
+
[1m[35m (0.1ms)[0m DROP TABLE "acustom_emails_emails"
|
1135
|
+
[1m[36m (0.1ms)[0m [1mDROP INDEX "index_custom_emails_email_kinds_on_name"[0m
|
1136
|
+
[1m[35m (0.1ms)[0m DROP TABLE "custom_emails_email_kinds"
|
1137
|
+
[1m[36mSQL (0.7ms)[0m [1mDELETE FROM "schema_migrations" WHERE "schema_migrations"."version" = '20131018143726'[0m
|
1138
|
+
[1m[35m (79.9ms)[0m commit transaction
|
1139
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
1140
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
1141
|
+
[1m[35mActiveRecord::SchemaMigration Load (0.1ms)[0m SELECT "schema_migrations".* FROM "schema_migrations"
|
1142
|
+
Migrating to CreateCustomEmailsEmails (20131018141445)
|
1143
|
+
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
1144
|
+
[1m[35m (0.2ms)[0m DROP INDEX "index_custom_emails_emails_on_emailable_id"
|
1145
|
+
[1m[36m (0.1ms)[0m [1mDROP INDEX "index_custom_emails_emails_on_locale"[0m
|
1146
|
+
[1m[35m (0.1ms)[0m DROP TABLE "custom_emails_emails"
|
1147
|
+
[1m[36mSQL (0.7ms)[0m [1mDELETE FROM "schema_migrations" WHERE "schema_migrations"."version" = '20131018141445'[0m
|
1148
|
+
[1m[35m (105.3ms)[0m commit transaction
|
1149
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
1150
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
1151
|
+
[1m[35mActiveRecord::SchemaMigration Load (0.1ms)[0m SELECT "schema_migrations".* FROM "schema_migrations"
|
1152
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
1153
|
+
Migrating to CreateCustomEmailsEmails (20131018141445)
|
1154
|
+
[1m[35m (0.0ms)[0m begin transaction
|
1155
|
+
[1m[36m (0.3ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime) [0m
|
1156
|
+
[1m[35m (0.1ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
1157
|
+
[1m[36m (0.1ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")[0m
|
1158
|
+
[1m[35mSQL (0.8ms)[0m INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20131018141445"]]
|
1159
|
+
[1m[36m (127.0ms)[0m [1mcommit transaction[0m
|
1160
|
+
Migrating to CreateCustomEmailsEmailKinds (20131018143726)
|
1161
|
+
[1m[35m (0.1ms)[0m begin transaction
|
1162
|
+
[1m[36m (0.4ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
1163
|
+
[1m[35m (0.3ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
1164
|
+
[1m[36m (0.3ms)[0m [1mALTER TABLE "custom_emails_emails" ADD "kind_id" integer[0m
|
1165
|
+
[1m[35m (0.2ms)[0m CREATE INDEX "index_custom_emails_emails_on_kind_id_and_emailable_id" ON "custom_emails_emails" ("kind_id", "emailable_id")
|
1166
|
+
[1m[36m (0.2ms)[0m [1mrollback transaction[0m
|
1167
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
1168
|
+
[1m[35mActiveRecord::SchemaMigration Load (0.1ms)[0m SELECT "schema_migrations".* FROM "schema_migrations"
|
1169
|
+
Migrating to CreateCustomEmailsEmails (20131018141445)
|
1170
|
+
[1m[36m (0.0ms)[0m [1mbegin transaction[0m
|
1171
|
+
[1m[35m (0.2ms)[0m DROP INDEX "index_custom_emails_emails_on_emailable_id"
|
1172
|
+
[1m[36m (0.1ms)[0m [1mDROP INDEX "index_custom_emails_emails_on_locale"[0m
|
1173
|
+
[1m[35m (0.1ms)[0m DROP TABLE "custom_emails_emails"
|
1174
|
+
[1m[36mSQL (0.7ms)[0m [1mDELETE FROM "schema_migrations" WHERE "schema_migrations"."version" = '20131018141445'[0m
|
1175
|
+
[1m[35m (118.5ms)[0m commit transaction
|
1176
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
1177
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
1178
|
+
[1m[35mActiveRecord::SchemaMigration Load (0.1ms)[0m SELECT "schema_migrations".* FROM "schema_migrations"
|
1179
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
1180
|
+
Migrating to CreateCustomEmailsEmails (20131018141445)
|
1181
|
+
[1m[35m (0.0ms)[0m begin transaction
|
1182
|
+
[1m[36m (0.3ms)[0m [1mCREATE TABLE "custom_emails_emails" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "emailable_id" integer, "emailable_type" varchar(255), "locale" varchar(255), "subject" text, "content_text" text, "content_html" text, "created_at" datetime, "updated_at" datetime) [0m
|
1183
|
+
[1m[35m (0.1ms)[0m CREATE INDEX "index_custom_emails_emails_on_locale" ON "custom_emails_emails" ("locale")
|
1184
|
+
[1m[36m (0.1ms)[0m [1mCREATE INDEX "index_custom_emails_emails_on_emailable_id" ON "custom_emails_emails" ("emailable_id")[0m
|
1185
|
+
[1m[35mSQL (0.8ms)[0m INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20131018141445"]]
|
1186
|
+
[1m[36m (188.7ms)[0m [1mcommit transaction[0m
|
1187
|
+
Migrating to CreateCustomEmailsEmailKinds (20131018143726)
|
1188
|
+
[1m[35m (0.1ms)[0m begin transaction
|
1189
|
+
[1m[36m (0.4ms)[0m [1mCREATE TABLE "custom_emails_email_kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) [0m
|
1190
|
+
[1m[35m (0.3ms)[0m CREATE UNIQUE INDEX "index_custom_emails_email_kinds_on_name" ON "custom_emails_email_kinds" ("name")
|
1191
|
+
[1m[36m (0.3ms)[0m [1mALTER TABLE "custom_emails_emails" ADD "kind_id" integer[0m
|
1192
|
+
[1m[35m (0.2ms)[0m CREATE INDEX "index_custom_emails_emails_on_kind_id_and_emailable_id" ON "custom_emails_emails" ("kind_id", "emailable_id")
|
1193
|
+
[1m[36m (0.3ms)[0m [1mCREATE UNIQUE INDEX "unique_w_kind_locale_and_emailable" ON "custom_emails_emails" ("kind_id", "locale", "emailable_id", "emailable_type")[0m
|
1194
|
+
[1m[35mSQL (0.1ms)[0m INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20131018143726"]]
|
1195
|
+
[1m[36m (95.7ms)[0m [1mcommit transaction[0m
|
1196
|
+
Migrating to CreateExamples (20131018164626)
|
1197
|
+
[1m[35m (0.1ms)[0m begin transaction
|
1198
|
+
[1m[36m (0.4ms)[0m [1mCREATE TABLE "examples" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL) [0m
|
1199
|
+
[1m[35mSQL (0.2ms)[0m INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20131018164626"]]
|
1200
|
+
[1m[36m (82.0ms)[0m [1mcommit transaction[0m
|
1201
|
+
[1m[35mActiveRecord::SchemaMigration Load (0.1ms)[0m SELECT "schema_migrations".* FROM "schema_migrations"
|