On 2013-03-03, at 21:16, stephane ducasse <[email protected]> wrote:
> I do not buy this argument you will have to show me. > > when I see > > self assert: contents = $A already in this case, looking at the debugger you're stuck with a silly message that doesn't give you the slightest hint of what is wrong. You don't see in the debugger "Got ... instead of $A". You have to write self assert: contents equals: $A to get a "Got ... instead of $A" message. Well now it is matter of style writing contents should = $A Look at all the tests in ReleaseTest, and you will see that we have to manually capture the contents before doing any assertion, otherwise the results on the build server are not of much use. Even if we have a serialized stack with fuel, there is no way I can get the result that was used for the comparison. That is unless I use #assert:equals: everywhere! > I do not see the difference with > contents should be equals: $A no, not #equals, you send #=, which is natural, and get a decent error message for free. > except that I do not understand what is be and that every object is extended > with should and friends. no need to use the #be. > Then I do not want to chain results of tests. > > Stef > >>> pfffff can we stop such kind of mess. >>> I frankly do not see the value of >> >> Think about the error messages here. >> >>> self should not be = $a >> >> Error message will be something like: Got 'adsfasdfasd' instead of $a >> >>> vs >>> self assert: self = $a >> >> and here? >> Assertion failed >> >> AKA 0 contextual information. Now it gets even worse when doing things like >> #should:raise: and friends. You have to fully restart the test case to even >> when debugging it just because you don't have decent error messages. >> >> Now this is what Phexample brings, 10 clicks less per failed assertion. >> I want that in 3.0. Besides in most cases a tree rewrite will do the proper >> transformation, so 0 effort for nice error messages. > > this is my point I do not see why I get something more complex that what we > already have. > > No need to reply I see that should construct a nice object whatever. Now to > me it does not help > me. I prefer to get a better Sunit. > > > > >>> I looked and most of the tests in Moose do not gain anything to rely on >>> phExample. >>> And now such change break nautilus. >> >> they don't break nautilus if the test in nautilus were implemented as I said >> before. >> >> > >
