added try catch for non-existing prop. updated test