Am wondering if this and line number 5 belong in a method on `Cookbook` like `@cookbook.get_version!(version)` or something. Might make things easier to test and I could see this behavior being useful else where. Maybe something like...

```ruby
def get_version!(version)
  version = version.gsub(/_/, '.')

  if version == 'latest'
    latest_cookbook_version!
  else
    cookbook_versions.find_by(version: version)
  end
end
```