[Cuis-dev] Test error message wrongly formatted

Hernán Wilkinson hernan.wilkinson at 10pines.com
Fri Jul 28 17:05:15 PDT 2023


Hi Hilaire,
 What is happening is correct.
 I mean, the first parameter has to be the expected object. That it is why
it says “Expected …” no matter what the parameter is.
 If you change your example for:
self assert: 'expected value’ equals: ‘actual value’
The message will be:
Expected ‘expected value’ but was ‘actual value’

I hope this help. Let me know if you have any other question

Cheers
Hernan

On Fri, 28 Jul 2023 at 19:35 Hilaire Fernandes via Cuis-dev <
cuis-dev at lists.cuis.st> wrote:

> Hi Juan,
>
> Your example does not use the message I was writing about. Try instead:
>
> TestCase new assert: 'actual value' equals: 'expected value'
>
> The Debugger message is then:
>
> TestFailure: Expected 'actual value' but was 'expected value'. -
> Process: Morphic UI - Priority: 40
>
> Hilaire
>
> Le 24/07/2023 à 15:13, Juan Vuletich a écrit :
> > If I evaluate:
> >
> > TestCase new assert: 'actual value' equalsExpected: 'expected value'
> >
> > I get a debugger with title:
> >
> > TestFailure: Expected 'expected value' but was 'actual value'. -
> > Process: Morphic UI - Priority: 40
> >
> > I think this is a correct error message. What message do you get with
> > this example? What message do you think it would be correct instead?
> --
> Cuis-dev mailing list
> Cuis-dev at lists.cuis.st
> https://lists.cuis.st/mailman/listinfo/cuis-dev
>
-- 

*Hernán WilkinsonAgile Software Development, Teaching & Coaching*
*Phone: +54-011*-4893-2057
*Twitter: @HernanWilkinson*
*site: http://www.10Pines.com <http://www.10pines.com/>*
Address: Alem 896, Floor 6, Buenos Aires, Argentina
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cuis.st/mailman/archives/cuis-dev/attachments/20230728/83ddc321/attachment.htm>


More information about the Cuis-dev mailing list