Add more unit tests for post creation.

Switch from Mocha to RSpec Mocks.  RSpec Mocks offers the stub_const
method which is the only way I could find to successfully mock out
calls to ENV.