diff options
Diffstat (limited to 'test/rake/test_rake_task_with_arguments.rb')
-rw-r--r-- | test/rake/test_rake_task_with_arguments.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/test/rake/test_rake_task_with_arguments.rb b/test/rake/test_rake_task_with_arguments.rb index bbbc82f99f..fe1bcf5a49 100644 --- a/test/rake/test_rake_task_with_arguments.rb +++ b/test/rake/test_rake_task_with_arguments.rb @@ -158,5 +158,13 @@ class TestRakeTaskWithArguments < Rake::TestCase t = task(:t => [:pre]) t.invoke("bill", "1.2") end + + def test_values_at + t = task(:pre, [:a, :b, :c]) { |t, args| + a, b, c = args.values_at(:a, :b, :c) + assert_equal %w[1 2 3], [a, b, c] + } + t.invoke(*%w[1 2 3]) + end end |