Add spec for warning messages when cache location is invalid
Add spec for warning messages when cache location is invalid

This PR suppresses the following warnings that are displayed
when running tests, and makes them executable test code.

```console
% cd path/to/rubocop
% bundle exec rspec ./spec/rubocop/result_cache_spec.rb:278
Run options: include {:focus=>true,
:locations=>{"./spec/rubocop/result_cache_spec.rb"=>[278]}}

Randomized with seed 7133
Couldn't create cache directory. Continuing without cache.
  Permission denied
.Couldn't create cache directory. Continuing without cache.
  Read-only file system
.

Finished in 0.20314 seconds (files took 1.93 seconds to load)
2 examples, 0 failures

Randomized with seed 7133
```

maxjacobson/rubocop,maxjacobson/rubocop,jmks/rubocop,deivid-rodriguez/rubocop,tdeo/rubocop,jmks/rubocop,rrosenblum/rubocop,rrosenblum/rubocop,tejasbubane/rubocop,tdeo/rubocop,rrosenblum/rubocop,maxjacobson/rubocop,bbatsov/rubocop,bbatsov/rubocop,tdeo/rubocop,deivid-rodriguez/rubocop,jmks/rubocop,tejasbubane/rubocop,tejasbubane/rubocop,deivid-rodriguez/rubocop