Use Mock object in interactive session test.