RSpec - have received method without arguments
If you ever find yourself in a situation that you have to check that some method should be called without any arguments you can use no_args
argument. For example:
expect(AwesomeService).to have_received(:call).with(no_args).once
expect(AwesomeService).to have_received(:call).with(force: true).once
Tweet