mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
cleanup railties test; fix typos
This commit is contained in:
parent
3b0b573ac3
commit
c0be6c9811
3 changed files with 5 additions and 6 deletions
|
@ -127,24 +127,23 @@ class FullStackConsoleTest < ActiveSupport::TestCase
|
|||
end
|
||||
|
||||
def spawn_console
|
||||
pid = Process.spawn(
|
||||
Process.spawn(
|
||||
"#{app_path}/bin/rails console --sandbox",
|
||||
in: @slave, out: @slave, err: @slave
|
||||
)
|
||||
|
||||
assert_output "> ", 30
|
||||
pid
|
||||
end
|
||||
|
||||
def test_sandbox
|
||||
pid = spawn_console
|
||||
spawn_console
|
||||
|
||||
write_prompt "Post.count", "=> 0"
|
||||
write_prompt "Post.create"
|
||||
write_prompt "Post.count", "=> 1"
|
||||
@master.puts "quit"
|
||||
|
||||
pid = spawn_console
|
||||
spawn_console
|
||||
|
||||
write_prompt "Post.count", "=> 0"
|
||||
write_prompt "Post.transaction { Post.create; raise }"
|
||||
|
|
|
@ -164,7 +164,7 @@ class GeneratorsTest < Rails::Generators::TestCase
|
|||
Rails::Generators.invoke "super_shoulda:model", ["Account"]
|
||||
end
|
||||
|
||||
def test_developer_options_are_overwriten_by_user_options
|
||||
def test_developer_options_are_overwritten_by_user_options
|
||||
Rails::Generators.options[:with_options] = { generate: false }
|
||||
|
||||
self.class.class_eval(<<-end_eval, __FILE__, __LINE__ + 1)
|
||||
|
|
|
@ -187,7 +187,7 @@ module RailtiesTest
|
|||
assert_equal "Hello bukkits\n", response[2].body
|
||||
end
|
||||
|
||||
test "adds its views to view paths with lower proriority than app ones" do
|
||||
test "adds its views to view paths with lower priority than app ones" do
|
||||
@plugin.write "app/controllers/bukkit_controller.rb", <<-RUBY
|
||||
class BukkitController < ActionController::Base
|
||||
def index
|
||||
|
|
Loading…
Reference in a new issue