rspec/rspec-rails — Issue #461: request.path_parameters has strings as keys, while in real environment it's symbols
Author: ndbroadbent
Created: 2011-11-11 04:00:35+00:00
State: open

Following on from [this comment](https://github.com/rspec/rspec-rails/issues/172#issuecomment-372586) on issue #172.

I'm writing tests for code that uses `controller.request.path_parameters`, but I have to use `symbolize_keys` in order to stay 'compatible' with RSpec:

```ruby
controller.request.path_parameters.symbolize_keys[:action]
```

`symbolize_keys` is an ok workaround, but I really think that the `path_parameters` should match those in the real Rails environment.

If you think it's a good idea, I'll change it to match Rails (`HashWithIndifferentAccess`, with symbols as keys), and send a pull request.