Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
张重言
rails
提交
f17159b0
R
rails
项目概览
张重言
/
rails
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
R
rails
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
f17159b0
编写于
6月 14, 2010
作者:
X
Xavier Noria
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
edit pass: the names of Rails components have a space, ie, "Active Record", not "ActiveRecord"
上级
b442edbf
变更
30
隐藏空白更改
内联
并排
Showing
30 changed file
with
48 addition
and
48 deletion
+48
-48
actionmailer/lib/action_mailer/base.rb
actionmailer/lib/action_mailer/base.rb
+2
-2
actionpack/lib/action_controller.rb
actionpack/lib/action_controller.rb
+1
-1
actionpack/lib/action_controller/metal/instrumentation.rb
actionpack/lib/action_controller/metal/instrumentation.rb
+1
-1
actionpack/lib/action_view/context.rb
actionpack/lib/action_view/context.rb
+3
-3
actionpack/lib/action_view/helpers/sanitize_helper.rb
actionpack/lib/action_view/helpers/sanitize_helper.rb
+1
-1
actionpack/lib/action_view/helpers/text_helper.rb
actionpack/lib/action_view/helpers/text_helper.rb
+1
-1
actionpack/test/controller/helper_test.rb
actionpack/test/controller/helper_test.rb
+1
-1
actionpack/test/controller/render_test.rb
actionpack/test/controller/render_test.rb
+1
-1
activemodel/lib/active_model/lint.rb
activemodel/lib/active_model/lint.rb
+1
-1
activemodel/lib/active_model/naming.rb
activemodel/lib/active_model/naming.rb
+1
-1
activemodel/lib/active_model/validator.rb
activemodel/lib/active_model/validator.rb
+1
-1
activerecord/lib/active_record/association_preload.rb
activerecord/lib/active_record/association_preload.rb
+6
-6
activerecord/lib/active_record/associations.rb
activerecord/lib/active_record/associations.rb
+2
-2
activerecord/lib/active_record/connection_adapters/abstract/connection_pool.rb
...ve_record/connection_adapters/abstract/connection_pool.rb
+6
-6
activerecord/lib/active_record/connection_adapters/abstract/connection_specification.rb
.../connection_adapters/abstract/connection_specification.rb
+1
-1
activerecord/lib/active_record/connection_adapters/abstract_adapter.rb
...lib/active_record/connection_adapters/abstract_adapter.rb
+2
-2
activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb
...b/active_record/connection_adapters/postgresql_adapter.rb
+3
-3
activerecord/lib/active_record/locale/en.yml
activerecord/lib/active_record/locale/en.yml
+1
-1
activerecord/test/cases/defaults_test.rb
activerecord/test/cases/defaults_test.rb
+1
-1
activeresource/test/cases/base_test.rb
activeresource/test/cases/base_test.rb
+1
-1
activeresource/test/cases/finder_test.rb
activeresource/test/cases/finder_test.rb
+1
-1
activesupport/lib/active_support/callbacks.rb
activesupport/lib/active_support/callbacks.rb
+1
-1
activesupport/lib/active_support/xml_mini/rexml.rb
activesupport/lib/active_support/xml_mini/rexml.rb
+1
-1
ci/site_config.rb
ci/site_config.rb
+2
-2
railties/lib/rails.rb
railties/lib/rails.rb
+1
-1
railties/lib/rails/log_subscriber.rb
railties/lib/rails/log_subscriber.rb
+1
-1
railties/lib/rails/log_subscriber/test_helper.rb
railties/lib/rails/log_subscriber/test_helper.rb
+1
-1
railties/lib/rails/railtie.rb
railties/lib/rails/railtie.rb
+1
-1
railties/lib/rails/test_unit/testing.rake
railties/lib/rails/test_unit/testing.rake
+1
-1
railties/test/application/initializers/notifications_test.rb
railties/test/application/initializers/notifications_test.rb
+1
-1
未找到文件。
actionmailer/lib/action_mailer/base.rb
浏览文件 @
f17159b0
...
...
@@ -209,7 +209,7 @@ module ActionMailer #:nodoc:
#
# <%= image_tag attachments['photo.png'].url -%>
#
# As we are using ActionView's +image_tag+ method, you can pass in any other options you want:
# As we are using Action
View's +image_tag+ method, you can pass in any other options you want:
#
# <h1>Please Don't Cringe</h1>
#
...
...
@@ -739,7 +739,7 @@ def deprecated_url_options
end
# This module will complain if the user tries to set default_url_options
# directly instead of through the config object. In ActionMailer's Railtie,
# directly instead of through the config object. In Action
Mailer's Railtie,
# we include the url_helpers of the router, which will override this module
extend
DeprecatedUrlOptions
...
...
actionpack/lib/action_controller.rb
浏览文件 @
f17159b0
...
...
@@ -67,7 +67,7 @@ module ActionController
require
'action_view'
require
'action_controller/vendor/html-scanner'
# Common Active
Support usage in Action
Controller
# Common Active
Support usage in Action
Controller
require
'active_support/concern'
require
'active_support/core_ext/class/attribute_accessors'
require
'active_support/core_ext/load_error'
...
...
actionpack/lib/action_controller/metal/instrumentation.rb
浏览文件 @
f17159b0
...
...
@@ -2,7 +2,7 @@
module
ActionController
# Adds instrumentation to several ends in ActionController::Base. It also provides
# some hooks related with process_action, this allows an ORM like ActiveRecord
# some hooks related with process_action, this allows an ORM like Active
Record
# and/or DataMapper to plug in ActionController and show related information.
#
# Check ActiveRecord::Railties::ControllerRuntime for an example.
...
...
actionpack/lib/action_view/context.rb
浏览文件 @
f17159b0
...
...
@@ -3,8 +3,8 @@ module CompiledTemplates #:nodoc:
# holds compiled template code
end
# Action
View contexts are supplied to Action
Controller
# to render template. The default ActionView context
# Action
View contexts are supplied to Action
Controller
# to render template. The default Action
View context
# is ActionView::Base.
#
# In order to work with ActionController, a Context
...
...
@@ -21,7 +21,7 @@ module CompiledTemplates #:nodoc:
# options<Hash>:: See _render_template_with_layout in ActionView::Base
# partial<Boolean>:: Whether or not the template to render is a partial
#
# An Action
View context can also mix in Action
View's
# An Action
View context can also mix in Action
View's
# helpers. In order to mix in helpers, a context must
# implement:
#
...
...
actionpack/lib/action_view/helpers/sanitize_helper.rb
浏览文件 @
f17159b0
...
...
@@ -4,7 +4,7 @@
module
ActionView
module
Helpers
#:nodoc:
# The SanitizeHelper module provides a set of methods for scrubbing text of undesired HTML elements.
# These helper methods extend ActionView making them callable within your template files.
# These helper methods extend Action
View making them callable within your template files.
module
SanitizeHelper
# This +sanitize+ helper will html encode all tags and strip all attributes that aren't specifically allowed.
# It also strips href/src tags with invalid protocols, like javascript: especially. It does its best to counter any
...
...
actionpack/lib/action_view/helpers/text_helper.rb
浏览文件 @
f17159b0
...
...
@@ -6,7 +6,7 @@ module ActionView
module
Helpers
#:nodoc:
# The TextHelper module provides a set of methods for filtering, formatting
# and transforming strings, which can reduce the amount of inline Ruby code in
# your views. These helper methods extend ActionView making them callable
# your views. These helper methods extend Action
View making them callable
# within your template files.
module
TextHelper
# The preferred method of outputting text in your views is to use the
...
...
actionpack/test/controller/helper_test.rb
浏览文件 @
f17159b0
...
...
@@ -122,7 +122,7 @@ def test_all_helpers_with_alternate_helper_dir
def
test_helper_proxy
methods
=
AllHelpersController
.
helpers
.
methods
.
map
(
&
:to_s
)
# ActionView
# Action
View
assert
methods
.
include?
(
'pluralize'
)
# abc_helper.rb
...
...
actionpack/test/controller/render_test.rb
浏览文件 @
f17159b0
...
...
@@ -275,7 +275,7 @@ def builder_layout_test
render
:action
=>
"hello"
,
:layout
=>
"layouts/builder"
end
# :move: test this in ActionView
# :move: test this in Action
View
def
builder_partial_test
render
:action
=>
"hello_world_container"
end
...
...
activemodel/lib/active_model/lint.rb
浏览文件 @
f17159b0
# == Active Model Lint Tests
#
# You can test whether an object is compliant with the ActiveModel API by
# You can test whether an object is compliant with the Active
Model API by
# including <tt>ActiveModel::Lint::Tests</tt> in your TestCase. It will include
# tests that tell you whether your object is fully compliant, or if not,
# which aspects of the API are not implemented.
...
...
activemodel/lib/active_model/naming.rb
浏览文件 @
f17159b0
...
...
@@ -49,7 +49,7 @@ def human(options={})
# BookCover.model_name.human #=> "Book cover"
#
# Providing the functionality that ActiveModel::Naming provides in your object
# is required to pass the ActiveModel Lint test. So either extending the provided
# is required to pass the Active
Model Lint test. So either extending the provided
# method below, or rolling your own is required..
module
Naming
# Returns an ActiveModel::Name object for module. It can be
...
...
activemodel/lib/active_model/validator.rb
浏览文件 @
f17159b0
...
...
@@ -130,7 +130,7 @@ def validate(record)
# in the options hash invoking the validate_each method passing in the
# record, attribute and value.
#
# All ActiveModel validations are built on top of this Validator.
# All Active
Model validations are built on top of this Validator.
class
EachValidator
<
Validator
attr_reader
:attributes
...
...
activerecord/lib/active_record/association_preload.rb
浏览文件 @
f17159b0
...
...
@@ -6,7 +6,7 @@ module ActiveRecord
module
AssociationPreload
#:nodoc:
extend
ActiveSupport
::
Concern
# Implements the details of eager loading of ActiveRecord associations.
# Implements the details of eager loading of Active
Record associations.
# Application developers should not use this module directly.
#
# ActiveRecord::Base is extended with this module. The source code in
...
...
@@ -18,7 +18,7 @@ module AssociationPreload #:nodoc:
# The first one is by using table joins. This was only strategy available
# prior to Rails 2.1. Suppose that you have an Author model with columns
# 'name' and 'age', and a Book model with columns 'name' and 'sales'. Using
# this strategy, ActiveRecord would try to retrieve all data for an author
# this strategy, Active
Record would try to retrieve all data for an author
# and all of its books via a single query:
#
# SELECT * FROM authors
...
...
@@ -31,7 +31,7 @@ module AssociationPreload #:nodoc:
# 'books' table is useful; the joined 'authors' data is just redundant, and
# processing this redundant data takes memory and CPU time. The problem
# quickly becomes worse and worse as the level of eager loading increases
# (i.e. if ActiveRecord is to eager load the associations' associations as
# (i.e. if Active
Record is to eager load the associations' associations as
# well).
#
# The second strategy is to use multiple database queries, one for each
...
...
@@ -45,7 +45,7 @@ module AssociationPreload #:nodoc:
module
ClassMethods
protected
# Eager loads the named associations for the given ActiveRecord record(s).
# Eager loads the named associations for the given Active
Record record(s).
#
# In this description, 'association name' shall refer to the name passed
# to an association creation method. For example, a model that specifies
...
...
@@ -80,7 +80,7 @@ module ClassMethods
# { :author => :avatar }
# [ :books, { :author => :avatar } ]
#
# +preload_options+ contains options that will be passed to ActiveRecord#find
# +preload_options+ contains options that will be passed to ActiveRecord
::Base
#find
# (which is called under the hood for preloading records). But it is passed
# only one level deep in the +associations+ argument, i.e. it's not passed
# to the child associations when +associations+ is a Hash.
...
...
@@ -166,7 +166,7 @@ def set_association_single_records(id_to_record_map, reflection_name, associated
end
end
# Given a collection of ActiveRecord objects, constructs a Hash which maps
# Given a collection of Active
Record objects, constructs a Hash which maps
# the objects' IDs to the relevant objects. Returns a 2-tuple
# <tt>(id_to_record_map, ids)</tt> where +id_to_record_map+ is the Hash,
# and +ids+ is an Array of record IDs.
...
...
activerecord/lib/active_record/associations.rb
浏览文件 @
f17159b0
...
...
@@ -711,7 +711,7 @@ def association_instance_set(name, association)
#
# The +traps+ association on +Dungeon+ and the the +dungeon+ association on +Trap+ are the inverse of each other and the
# inverse of the +dungeon+ association on +EvilWizard+ is the +evil_wizard+ association on +Dungeon+ (and vice-versa). By default,
#
+ActiveRecord+ doesn't do
know anything about these inverse relationships and so no object loading optimisation is possible. For example:
#
Active Record doesn't
know anything about these inverse relationships and so no object loading optimisation is possible. For example:
#
# d = Dungeon.first
# t = d.traps.first
...
...
@@ -721,7 +721,7 @@ def association_instance_set(name, association)
#
# The +Dungeon+ instances +d+ and <tt>t.dungeon</tt> in the above example refer to the same object data from the database, but are
# actually different in-memory copies of that data. Specifying the <tt>:inverse_of</tt> option on associations lets you tell
#
+ActiveRecord+
about inverse relationships and it will optimise object loading. For example, if we changed our model definitions to:
#
Active Record
about inverse relationships and it will optimise object loading. For example, if we changed our model definitions to:
#
# class Dungeon < ActiveRecord::Base
# has_many :traps, :inverse_of => :dungeon
...
...
activerecord/lib/active_record/connection_adapters/abstract/connection_pool.rb
浏览文件 @
f17159b0
...
...
@@ -9,7 +9,7 @@ class ConnectionTimeoutError < ConnectionNotEstablished
end
module
ConnectionAdapters
# Connection pool base class for managing ActiveRecord database
# Connection pool base class for managing Active
Record database
# connections.
#
# == Introduction
...
...
@@ -30,12 +30,12 @@ module ConnectionAdapters
# Connections can be obtained and used from a connection pool in several
# ways:
#
# 1. Simply use ActiveRecord::Base.connection as with ActiveRecord 2.1 and
# 1. Simply use ActiveRecord::Base.connection as with Active
Record 2.1 and
# earlier (pre-connection-pooling). Eventually, when you're done with
# the connection(s) and wish it to be returned to the pool, you call
# ActiveRecord::Base.clear_active_connections!. This will be the
# default behavior for ActiveRecord when used in conjunction with
# ActionPack's request handling cycle.
# default behavior for Active
Record when used in conjunction with
# Action
Pack's request handling cycle.
# 2. Manually check out a connection from the pool with
# ActiveRecord::Base.connection_pool.checkout. You are responsible for
# returning this connection to the pool when finished by calling
...
...
@@ -265,7 +265,7 @@ def checkout_and_verify(c)
end
# ConnectionHandler is a collection of ConnectionPool objects. It is used
# for keeping separate connection pools for ActiveRecord models that connect
# for keeping separate connection pools for Active
Record models that connect
# to different databases.
#
# For example, suppose that you have 5 models, with the following hierarchy:
...
...
@@ -285,7 +285,7 @@ def checkout_and_verify(c)
# is not the same as the one used by Book/ScaryBook/GoodBook.
#
# Normally there is only a single ConnectionHandler instance, accessible via
# ActiveRecord::Base.connection_handler. ActiveRecord models use this to
# ActiveRecord::Base.connection_handler. Active
Record models use this to
# determine that connection pool that they should use.
class
ConnectionHandler
def
initialize
(
pools
=
{})
...
...
activerecord/lib/active_record/connection_adapters/abstract/connection_specification.rb
浏览文件 @
f17159b0
...
...
@@ -103,7 +103,7 @@ def retrieve_connection
connection_handler
.
retrieve_connection
(
self
)
end
# Returns true if
+ActiveRecord+
is connected.
# Returns true if
Active Record
is connected.
def
connected?
connection_handler
.
connected?
(
self
)
end
...
...
activerecord/lib/active_record/connection_adapters/abstract_adapter.rb
浏览文件 @
f17159b0
...
...
@@ -15,7 +15,7 @@
module
ActiveRecord
module
ConnectionAdapters
# :nodoc:
# ActiveRecord supports multiple database systems. AbstractAdapter and
# Active
Record supports multiple database systems. AbstractAdapter and
# related classes form the abstraction layer which makes this possible.
# An AbstractAdapter represents a connection to a database, and provides an
# abstract interface for database-specific functionality such as establishing
...
...
@@ -59,7 +59,7 @@ def supports_migrations?
end
# Can this adapter determine the primary key for tables not attached
# to an ActiveRecord class, such as join tables? Backend specific, as
# to an Active
Record class, such as join tables? Backend specific, as
# the abstract adapter always returns +false+.
def
supports_primary_key?
false
...
...
activerecord/lib/active_record/connection_adapters/postgresql_adapter.rb
浏览文件 @
f17159b0
...
...
@@ -224,7 +224,7 @@ def active?
if
@connection
.
respond_to?
(
:status
)
@connection
.
status
==
PGconn
::
CONNECTION_OK
else
# We're asking the driver, not ActiveRecord, so use @connection.query instead of #query
# We're asking the driver, not Active
Record, so use @connection.query instead of #query
@connection
.
query
'SELECT 1'
true
end
...
...
@@ -258,7 +258,7 @@ def supports_migrations?
true
end
# Does PostgreSQL support finding primary key on non-ActiveRecord tables?
# Does PostgreSQL support finding primary key on non-Active
Record tables?
def
supports_primary_key?
#:nodoc:
true
end
...
...
@@ -925,7 +925,7 @@ def configure_connection
# Use standard-conforming strings if available so we don't have to do the E'...' dance.
set_standard_conforming_strings
# If using ActiveRecord's time zone support configure the connection to return
# If using Active
Record's time zone support configure the connection to return
# TIMESTAMP WITH ZONE types in UTC.
execute
(
"SET time zone 'UTC'"
)
if
ActiveRecord
::
Base
.
default_timezone
==
:utc
end
...
...
activerecord/lib/active_record/locale/en.yml
浏览文件 @
f17159b0
...
...
@@ -4,7 +4,7 @@ en:
#created_at: "Created at"
#updated_at: "Updated at"
# ActiveRecord models configuration
# Active
Record models configuration
activerecord
:
errors
:
messages
:
...
...
activerecord/test/cases/defaults_test.rb
浏览文件 @
f17159b0
...
...
@@ -43,7 +43,7 @@ def test_multiline_default_text
class
DefaultsTestWithoutTransactionalFixtures
<
ActiveRecord
::
TestCase
# ActiveRecord::Base#create! (and #save and other related methods) will
# open a new transaction. When in transactional fixtures mode, this will
# cause ActiveRecord to create a new savepoint. However, since MySQL doesn't
# cause Active
Record to create a new savepoint. However, since MySQL doesn't
# support DDL transactions, creating a table will result in any created
# savepoints to be automatically released. This in turn causes the savepoint
# release code in AbstractAdapter#transaction to fail.
...
...
activeresource/test/cases/base_test.rb
浏览文件 @
f17159b0
...
...
@@ -52,7 +52,7 @@ def setup
:children
=>
[{
:name
=>
'Natacha'
}]},
{
:name
=>
'Milena'
,
:children
=>
[]}]}]}.
to_xml
(
:root
=>
'customer'
)
# - resource with yaml array of strings; for A
ctiveRecord
s using serialize :bar, Array
# - resource with yaml array of strings; for A
R
s using serialize :bar, Array
@marty
=
<<-
eof
.
strip
<?xml version=
\"
1.0
\"
encoding=
\"
UTF-8
\"
?>
<person>
...
...
activeresource/test/cases/finder_test.rb
浏览文件 @
f17159b0
...
...
@@ -50,7 +50,7 @@ def setup
:children
=>
[{
:name
=>
'Natacha'
}]},
{
:name
=>
'Milena'
,
:children
=>
[]}]}]}.
to_xml
(
:root
=>
'customer'
)
# - resource with yaml array of strings; for A
ctiveRecord
s using serialize :bar, Array
# - resource with yaml array of strings; for A
R
s using serialize :bar, Array
@marty
=
<<-
eof
.
strip
<?xml version=
\"
1.0
\"
encoding=
\"
UTF-8
\"
?>
<person>
...
...
activesupport/lib/active_support/callbacks.rb
浏览文件 @
f17159b0
...
...
@@ -445,7 +445,7 @@ def __update_callbacks(name, filters = [], block = nil) #:nodoc:
# Use skip_callback to skip any defined one.
#
# When creating or skipping callbacks, you can specify conditions that
# are always the same for a given key. For instance, in ActionPack,
# are always the same for a given key. For instance, in Action
Pack,
# we convert :only and :except conditions into per-key conditions.
#
# before_filter :authenticate, :except => "index"
...
...
activesupport/lib/active_support/xml_mini/rexml.rb
浏览文件 @
f17159b0
...
...
@@ -11,7 +11,7 @@ module XmlMini_REXML #:nodoc:
# Parse an XML Document string or IO into a simple hash
#
# Same as XmlSimple::xml_in but doesn't shoot itself in the foot,
# and uses the defaults from Active
Support
# and uses the defaults from Active
Support.
#
# data::
# XML Document string or IO to parse
...
...
ci/site_config.rb
浏览文件 @
f17159b0
...
...
@@ -6,8 +6,8 @@
# EMAIL NOTIFICATION
# ------------------
# CruiseControl.rb can notify you about build status via email. It uses
Action
Mailer component of Ruby on Rails
# framework. Obviously, ActionMailer needs to know how to send out email messages.
# CruiseControl.rb can notify you about build status via email. It uses
the Action
Mailer component of Ruby on Rails
# framework. Obviously, Action
Mailer needs to know how to send out email messages.
# If you have an SMTP server on your network, and it needs no authentication, write this in your site_config.rb:
#
ActionMailer
::
Base
.
smtp_settings
=
{
...
...
railties/lib/rails.rb
浏览文件 @
f17159b0
...
...
@@ -67,7 +67,7 @@ def logger=(logger)
def
backtrace_cleaner
@@backtrace_cleaner
||=
begin
# Relies on ActiveSupport, so we have to lazy load to postpone definition until AS has been loaded
# Relies on Active
Support, so we have to lazy load to postpone definition until AS has been loaded
require
'rails/backtrace_cleaner'
Rails
::
BacktraceCleaner
.
new
end
...
...
railties/lib/rails/log_subscriber.rb
浏览文件 @
f17159b0
...
...
@@ -6,7 +6,7 @@ module Rails
# on initialization with solely purpose of logging. The log subscriber dispatches
# notifications to a regirested object based on its given namespace.
#
# An example would be ActiveRecord log subscriber responsible for logging queries:
# An example would be Active
Record log subscriber responsible for logging queries:
#
# module ActiveRecord
# class Railtie
...
...
railties/lib/rails/log_subscriber/test_helper.rb
浏览文件 @
f17159b0
...
...
@@ -3,7 +3,7 @@
module
Rails
class
LogSubscriber
# Provides some helpers to deal with testing log subscribers by setting up
# notifications. Take for instance ActiveRecord subscriber tests:
# notifications. Take for instance Active
Record subscriber tests:
#
# class SyncLogSubscriberTest < ActiveSupport::TestCase
# include Rails::LogSubscriber::TestHelper
...
...
railties/lib/rails/railtie.rb
浏览文件 @
f17159b0
...
...
@@ -10,7 +10,7 @@ module Rails
# Every major component of Rails (Action Mailer, Action Controller,
# Action View, Active Record and Active Resource) are all Railties, so each of
# them is responsible to set their own initialization. This makes, for example,
# Rails absent of any ActiveRecord hook, allowing any other ORM framework to hook in.
# Rails absent of any Active
Record hook, allowing any other ORM framework to hook in.
#
# Developing a Rails extension does _not_ require any implementation of
# Railtie, but if you need to interact with the Rails framework during
...
...
railties/lib/rails/test_unit/testing.rake
浏览文件 @
f17159b0
...
...
@@ -58,7 +58,7 @@ def recent_tests(source_pattern, test_path, touched_since = 10.minutes.ago)
end
# Recreated here from ActiveSupport because :uncommitted needs it before Rails is available
# Recreated here from Active
Support because :uncommitted needs it before Rails is available
module
Kernel
def
silence_stderr
old_stderr
=
STDERR
.
dup
...
...
railties/test/application/initializers/notifications_test.rb
浏览文件 @
f17159b0
...
...
@@ -37,7 +37,7 @@ def wait
ActiveRecord
::
Base
.
logger
=
logger
=
MockLogger
.
new
# Mimic ActiveRecord notifications
# Mimic Active
Record notifications
instrument
"sql.active_record"
,
:name
=>
"SQL"
,
:sql
=>
"SHOW tables"
wait
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录