Updated example with new $expect method