Added support for stubs as well as the existing expectations.