NonNil matcher producing incorrect result