Adding a helper method and a custom RSpec matcher