diff options
author | Xavier Noria <fxn@hashref.com> | 2016-08-06 20:20:22 +0200 |
---|---|---|
committer | Xavier Noria <fxn@hashref.com> | 2016-08-06 20:20:22 +0200 |
commit | b326e82dc012d81e9698cb1f402502af1788c1e9 (patch) | |
tree | 6b6452129a5b6b684f3d44f21afd2b1bea83fa22 /actionpack/test/journey | |
parent | 80e66cc4d90bf8c15d1a5f6e3152e90147f00772 (diff) | |
download | rails-b326e82dc012d81e9698cb1f402502af1788c1e9.tar.gz rails-b326e82dc012d81e9698cb1f402502af1788c1e9.tar.bz2 rails-b326e82dc012d81e9698cb1f402502af1788c1e9.zip |
applies remaining conventions across the project
Diffstat (limited to 'actionpack/test/journey')
7 files changed, 13 insertions, 13 deletions
diff --git a/actionpack/test/journey/gtg/builder_test.rb b/actionpack/test/journey/gtg/builder_test.rb index 5861cd2414..2b314cdd4e 100644 --- a/actionpack/test/journey/gtg/builder_test.rb +++ b/actionpack/test/journey/gtg/builder_test.rb @@ -59,7 +59,7 @@ module ActionDispatch end private - def ast strings + def ast(strings) parser = Journey::Parser.new asts = strings.map { |string| memo = Object.new @@ -70,7 +70,7 @@ module ActionDispatch Nodes::Or.new asts end - def tt strings + def tt(strings) Builder.new(ast(strings)).transition_table end end diff --git a/actionpack/test/journey/gtg/transition_table_test.rb b/actionpack/test/journey/gtg/transition_table_test.rb index 566eb4d186..23b05cc5f6 100644 --- a/actionpack/test/journey/gtg/transition_table_test.rb +++ b/actionpack/test/journey/gtg/transition_table_test.rb @@ -91,7 +91,7 @@ module ActionDispatch end private - def asts paths + def asts(paths) parser = Journey::Parser.new paths.map { |x| ast = parser.parse x @@ -100,13 +100,13 @@ module ActionDispatch } end - def tt paths + def tt(paths) x = asts paths builder = GTG::Builder.new Nodes::Or.new x builder.transition_table end - def simulator_for paths + def simulator_for(paths) GTG::Simulator.new tt(paths) end end diff --git a/actionpack/test/journey/nfa/simulator_test.rb b/actionpack/test/journey/nfa/simulator_test.rb index 117208c4a4..918b971fec 100644 --- a/actionpack/test/journey/nfa/simulator_test.rb +++ b/actionpack/test/journey/nfa/simulator_test.rb @@ -86,7 +86,7 @@ module ActionDispatch assert_equal [asts.first], md.memos end - def simulator_for paths + def simulator_for(paths) parser = Journey::Parser.new asts = paths.map { |x| parser.parse x } builder = Builder.new Nodes::Or.new asts diff --git a/actionpack/test/journey/nfa/transition_table_test.rb b/actionpack/test/journey/nfa/transition_table_test.rb index c948880c47..f3cf36a064 100644 --- a/actionpack/test/journey/nfa/transition_table_test.rb +++ b/actionpack/test/journey/nfa/transition_table_test.rb @@ -61,7 +61,7 @@ module ActionDispatch end private - def tt string + def tt(string) ast = @parser.parse string builder = Builder.new ast builder.transition_table diff --git a/actionpack/test/journey/route/definition/parser_test.rb b/actionpack/test/journey/route/definition/parser_test.rb index 8e00d8ab89..8c6e3c0371 100644 --- a/actionpack/test/journey/route/definition/parser_test.rb +++ b/actionpack/test/journey/route/definition/parser_test.rb @@ -101,7 +101,7 @@ module ActionDispatch assert_round_trip "/(:locale)(.:format)" end - def assert_round_trip str + def assert_round_trip(str) assert_equal str, @parser.parse(str).to_s end end diff --git a/actionpack/test/journey/route/definition/scanner_test.rb b/actionpack/test/journey/route/definition/scanner_test.rb index 82a50cf539..98578ddbf1 100644 --- a/actionpack/test/journey/route/definition/scanner_test.rb +++ b/actionpack/test/journey/route/definition/scanner_test.rb @@ -56,7 +56,7 @@ module ActionDispatch end end - def assert_tokens tokens, scanner + def assert_tokens(tokens, scanner) toks = [] while tok = scanner.next_token toks << tok diff --git a/actionpack/test/journey/router_test.rb b/actionpack/test/journey/router_test.rb index efe7bef5c5..c75475bffb 100644 --- a/actionpack/test/journey/router_test.rb +++ b/actionpack/test/journey/router_test.rb @@ -493,23 +493,23 @@ module ActionDispatch private - def get *args + def get(*args) ActiveSupport::Deprecation.silence do mapper.get(*args) end end - def match *args + def match(*args) ActiveSupport::Deprecation.silence do mapper.match(*args) end end - def rails_env env, klass = ActionDispatch::Request + def rails_env(env, klass = ActionDispatch::Request) klass.new(rack_env(env)) end - def rack_env env + def rack_env(env) { "rack.version" => [1, 1], "rack.input" => StringIO.new, |