I changed the Bitly test to actually fail on the assertion instead of the stub being incorrect.
The Cloudinary test behaves the same.
I had to add helper modules to add a file upload to the test.
Because post params now contains the IO stream for the uploaded image, but we don't intend to store the image itself in the Post model, I have introduced a second .permit when the Post instance is created/updated. This makes the code a bit wetter.
The Cloudinary gem works fine :)
Sigh - I checked in my secrets.yml file in a previous commit, so it's deleted now (and yeah, I reset my API key, not that it matters.)
.permit
when the Post instance is created/updated. This makes the code a bit wetter.