Closed toby-griffiths closed 1 year ago
well, given that the failure message is never used, I don't think swapping them has a big impact. Do you faced an actual issue caused by that ?
@stof I see your point. I think I just must have spotted it whilst step debugging, but I realise now it doen't actually make a difference.
I've just been trying t debug an issue with a failing method call, and in the process I spotted that what it was claiming was the actual, was in fact the expected value, and vice versa.
I tracked the issue down to this line, which seems to me to pass in the arguments the wrong way around…
https://github.com/phpspec/prophecy/blob/be1996ed8adc35c3fd795488a653f4b518be70ea/src/Prophecy/Argument/Token/ExactValueToken.php#L60
Am I wrong in thinking that the argument being scored should be the actual value, and the
$this->value
be the expected one when passing them toassertEquals()
?