This project is archived and is in readonly mode.

#1654 ✓resolved
CancelProfileIsBroken

Template generator should use predictable order for gem options

Reported by CancelProfileIsBroken | December 28th, 2008 @ 05:01 PM | in 2.x

test_gem_with_options_should_include_options_in_gem_dependency_in_environment is failing because the underlying code uses inject, which depends on Hash#each to order things, and the test assumes lexical order, which Hash#each does not guarantee.

In addition, Hash#each uses a different ordering in Ruby 1.9.

Attached patch (1) Sorts the generated options from TemplateRunner#gem so that we get predictable output regardless of Ruby version and (2) Fixes the test to assert that order.

Comments and changes to this ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>

People watching this ticket

Attachments

Referenced by

Pages