Verify the ordering of spies.

Register invokation order of calls and use it to verify that spies
have been called in order correctly.

Fixes #430.