Re: [PHPUnit] FeatureRequest
| From: | Christian Dickmann | Date: | Mon, 20 May 2002 13:29:03 +0000 |
| Subject: | Re: [PHPUnit] FeatureRequest | ||
| References: | 1 2 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-6232@lists.php.net to get a copy of this message | ||
> > This is possible with PHPUnit, but I would like to see
> > the error thrown by MDB. This means adding another
> > param to assertTrue which takes a message which is
> > printed when test "passed".
>
> The PHPUnit API mimics the JUnit API, so I don't want to change it
> lightly.
>
> Are you sure you can't solve your problem another way? Perhaps looking
> at a JUnit tutorial may yield insights how testing of error management
> is done in the promised l^a^a^a "Java World".
I had a look at the PHPUnit source.
I did some changes, which do not change its current behavior,
unless a optional parameter is passed to assertTrue().
The attached Patch shows the way, but its more a hack to show
that it is possible.
Christian Dickmann
begin 666 PHPUnit.20_05_02.diff.txt
M26YD97@Z(%!(4%5N:70O4$A056YI=%]!<W-E<G0N<&AP"CT]/3T]/3T]/3T]
M/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]
M/3T]/3T]/3T]/3T*4D-3(&9I;&4Z("]R97!O<VET;W)Y+W!E87(O4$A056YI
M="]02%!5;FET7T%S<V5R="YP:' L=@IR971R:65V:6YG(')E=FES:6]N(#$N
M,@ID:69F("UU("UR,2XR(%!(4%5N:71?07-S97)T+G!H< HM+2T@4$A056YI
M="]02%!5;FET7T%S<V5R="YP:' ),3$@1&5C(#(P,#$@,3DZ-#4Z-3(@+3 P
M,# ),2XR"BLK*R!02%!5;FET+U!(4%5N:71?07-S97)T+G!H< DR,"!-87D@
M,C P,B Q,SHR.#HR-B M,# P, I 0" M,3$X+#<@*S$Q."PW($! "B @(" @
M*B! <&%R86T@('-T<FEN9PH@(" @("H@0&%C8V5S<R!P=6)L:6,*("
@(" J
M+PHM(" @(&9U;F-T:6]N(&%S<V5R=%1R=64H)&-O;F1I=&EO;BP@)&UE<W-A
M9V4@/2 G)RD@>PHK(" @(&9U;F-T:6]N(&%S<V5R=%1R=64H)&-O;F1I=&EO
M;BP@)&UE<W-A9V4@/2 G)RP@)'!A<W-M97-S86=E(#T@)R<I('L*(" @(" @
M(" @:68@*&5M<'1Y*"1M97-S86=E*2D@>PH@(" @(" @(" @("
@)&UE<W-A
M9V4@/2 G97AP96-T960@=')U92P@86-T=6%L(&9A;'-E)SL*(" @(" @(" @
M?0I 0" M,3(W+#<@*S$R-RPW($! "B @(" @(" @("
@("!R971U<FX@)'1H
M:7,M/F9A:6PH)&UE<W-A9V4I.PH@(" @(" @("!]"B *+2 @(" @("
@<F5T
M=7)N("1T:&ES+3YP87-S*"D["BL@(" @(" @(')E='5R;B
D=&AI<RT^<&%S
M<R@D<&%S<VUE<W-A9V4I.PH@(" @('T*( H@(" @("\J*@I 0"
M,30T+#<@
M*S$T-"PW($! "B @(" @*@H@(" @("H@0&%C8V5S<R!P<F]T96-T960*("
@
M(" J+PHM(" @(&9U;F-T:6]N('!A<W,H*2E<&]S:71O<GDO<&5A<B]02%!5;FET+U!(4%5N:71?
M5&5S=$-A<V4N<&AP+'8*<F5T<FEE=FEN9R!R979I<VEO;B Q+C,*9&EF9B M
M=2 M<C$N,R!02%!5;FET7U1E<W1#87-E+G!H< HM+2T@4$A056YI="]02%!5
M;FET7U1E<W1#87-E+G!H< DY($%P<B R,# R(#$W.C0Y.C(P("TP,# P"3$N
M,PHK*RL@4$A056YI="]02%!5;FET7U1E<W1#87-E+G!H< DR,"!-87D@,C P
M,B Q,SHR.#HR-B M,# P, I 0" M,3DR+#@@*S$Y,BPX($! "B @(" @*@H@
M(" @("H@0&%C8V5S<R!P<F]T96-T960*(" @(" J+PHM(" @(&9U;F-T:6]N
M('!A<W,H*2!["BT@(" @(" @("1T:&ES+3Y?<F5S=6QT+3YA9&1087-S9614
M97-T*"1T:&ES*3L**R @("!F=6YC=&EO;B!P87-S*"1M97-S86=E(#T@)R<I
M('L**R @(" @(" @)'1H:7,M/E]R97-U;'0M/F%D9%!A<W-E9%1E<W0H)'1H
M:7,L("1M97-S86=E*3L*(" @("!]"B *( I);F1E>#H@4$A056YI="]02%!5
M;FET7U1E<W1297-U;'0N<&AP"CT]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]
M/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T]/3T*4D-3
M(&9I;&4Z("]R97!O<VET;W)Y+W!E87(O4$A056YI="]02%!5;FET7U1E<W12
M97-U;'0N<&AP+'8*<F5T<FEE=FEN9R!R979I<VEO;B Q+C,*9&EF9B M=2 M
M<C$N,R!02%!5;FET7U1E<W1297-U;'0N<&AP"BTM+2!02%!5;FET+U!(4%5N
M:71?5&5S=%)E<W5L="YP:' ).2!!<'(@,C P,B Q-SHT.3HR," M,# P, DQ
M+C,**RLK(%!(4%5N:70O4$A056YI=%]497-T4F5S=6QT+G!H< DR,"!-87D@
M,C P,B Q,SHR.#HR-R M,# P, I 0" M,3 U+#@@*S$P-2PX($! "B @(" @
M*B! <&%R86T@(&]B:F5C= H@(" @("H@0&%C8V5S<R!P=6)L:6,*(" @(" J
M+PHM(" @(&9U;F-T:6]N(&%D9%!A<W-E9%1E<W0H)B1T97-T*2B1T97-T+" D;65S<V%G92 ]("<G*2R<["B *(" @(" @("
@9F]R96%C
M:" H)'1H:7,M/E]P87-S961497-T<R!A<R
D<&%S<V5D5&5S="D@>PHM(" @
M(" @(" @(" @)')E<W5L=" N/2!S<')I;G1F*")497-T0V%S92
E<RT^)7,H
M*2!P87-S961<;B(L"BL@(" @(" @(" @("
D<F5S=6QT("X]('-P<FEN=&8H
M(E1E<W1#87-E("5S+3XE<R@I('!A<W-E9"5S7&XB+ H@"BT@(" @("
@(" @
M(" @(" @(" @(" @(" @(" @("
@9V5T7V-L87-S*"1P87-S961497-T*2P*
M+2 @(" @(" @(" @(" @(" @(" @(" @(" @(" @("
D<&%S<V5D5&5S="T^
M9V5T3F%M92@I"BL@(" @(" @(" @(" @(" @(" @(" @("
@(" @(" @9V5T
M7V-L87-S*"1P87-S961497-T6S!=*2P**R @(" @(" @(" @(" @(" @(" @
M(" @(" @(" @(" D<&%S<V5D5&5S=%LP72T^9V5T3F%M92@I+ HK("
@(" @
M(" @(" @(" @(" @(" @(" @(" @("
@("AE;7!T>2@D<&%S<V5D5&5S=%LQ
M72D_)R<Z)SH@)RXD<&%S<V5D5&5S=%LQ72D*(" @(" @(" @(" @("
@(" @
=(" @(" @(" @(" @("D["B @(" @(" @('T*( H`
`
end