Search the web
Sign In
New User? Sign Up
junit · JUnit, the Java unit testing framework written by Kent Beck and Erich Gamma.
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Message search is now enhanced, find messages faster. Take it for a spin.

Best of Y! Groups

   Check them out and nominate your group.
Having problems with message search? Fill out this form to ensure your group is one of the first to be migrated to the new message search system.

Messages

  Messages Help
Advanced
Messages 15910 - 15939 of 22044   Oldest  |  < Older  |  Newer >  |  Newest
Messages: Simplify | Expand   (Group by Topic) Author Sort by Date ^
15910
Hi, Could you please give me some CLUE, on how to proceed to test the following method: public int decide(LoggingEvent inEvent) { boolean retCode = false; if...
Kamal Ahmed
KAhmed@...
Send Email
Feb 1, 2006
3:37 pm
15911
Kamal, Welcome. ... Yes. ... How do you create LoggingEvents elsewhere? Is it as simple as new LoggingEvent(some parameters)? If so, that's how I'd proceed ...
David Saff
dsaff
Offline Send Email
Feb 1, 2006
4:00 pm
15912
David, Thank for your response, I have just read the cookbook: I think you are referring to: public void testMoneyMoneyBag() { // [12 CHF] + [14 CHF] + [28...
Kamal Ahmed
KAhmed@...
Send Email
Feb 1, 2006
4:42 pm
15913
... Pass in a mock LoggingEvent. Google for mock objects. -- Jason Rogers "I am crucified with Christ: nevertheless I live; yet not I, but Christ liveth in...
Jason Rogers
jacaetev
Offline Send Email
Feb 1, 2006
4:56 pm
15914
... That is definitely not true. LoggingEvent is a public class with a public constructor. Refer to the javadoc for LoggingEvent here: ...
Bradley, Todd
todd404
Offline Send Email
Feb 1, 2006
5:02 pm
15915
... What would happen if I have: @Test (expected=Bar.class) public void testMyFoo () {} If we execute junit3 style, it will find this test case, but won't see ...
Ben Maurer
benjamindavi...
Offline Send Email
Feb 1, 2006
6:10 pm
15916
Todd, Thanks, this certainly helped. I have tried to come up with a LoggingEvent (see snippet below) , is this what you were referring to? public void...
Kamal Ahmed
KAhmed@...
Send Email
Feb 1, 2006
8:00 pm
15917
... If the class doesn't inherit from TestCase, then only the JUnit 4 behavior will work. If it does, then you should probably disambiguate anyway, for which...
David Saff
dsaff
Offline Send Email
Feb 1, 2006
8:30 pm
15918
... Yes, that's what I meant. Todd....
Bradley, Todd
todd404
Offline Send Email
Feb 1, 2006
8:37 pm
15919
Thanks, Todd. Sorry to bother you again, but when I use the following test case, I get error: public void testdecide() { Logger logger = Logger ...
Kamal Ahmed
KAhmed@...
Send Email
Feb 1, 2006
10:18 pm
15920
Todd, The following change fixed it: public void testdecide() { Logger logger = Logger .getLogger("com.webmethods.sc.logging.test.unit.WmLoggerFilterTes"); ...
Kamal Ahmed
KAhmed@...
Send Email
Feb 2, 2006
12:13 am
15921
... I noticed that the author points out the danger of using Pluggable Selector and reflection in general. What's up with that? Why do so many people find...
J. B. Rainsberger
nails762
Offline Send Email
Feb 2, 2006
4:41 am
15922
... Read the recipe about "Abstract Test Case", somewhere in the first few chapters. It should be able to explain the idea more completely to you. By the way,...
J. B. Rainsberger
nails762
Offline Send Email
Feb 2, 2006
5:19 am
15923
... Yes. ... new LoggingEvent(...); The first test I'd write is this: public void testNull() { assertEquals( Filter.DENY, new WmLoggerFilter().decide(null) ); ...
J. B. Rainsberger
nails762
Offline Send Email
Feb 2, 2006
5:25 am
15924
... - Loss of static typing - Can break when refactoring - Performance overhead -- Cédric [Non-text portions of this message have been removed]...
Cédric Beust 
cbeust
Offline Send Email
Feb 2, 2006
6:44 am
15925
I don't think the performance overhead associated with reflection is as much of an issue as it was in early versions of Java, but the loss of static typing...
Stephen Smith
steve@...
Send Email
Feb 2, 2006
9:12 am
15926
Mark, What an interesting idea. I've never considered instrumenting functional code in a manner "altering" unit test execution. However, the notion of...
Marvin Toll
y153446
Offline Send Email
Feb 2, 2006
11:38 am
15927
... They don't have good Unit Tests? ... -- Daryl...
Daryl Richter
n_going_zax
Offline Send Email
Feb 2, 2006
1:01 pm
15928
... Not true. You would UnitTest it the same way as you test anything else. -- Jason Rogers "I am crucified with Christ: nevertheless I live; yet not I, but...
Jason Rogers
jacaetev
Offline Send Email
Feb 2, 2006
1:36 pm
15929
... In small spurts, no. But if it's used in a heavily used part of your system performance degradation takes place very quickly! -- Jason Rogers "I am...
Jason Rogers
jacaetev
Offline Send Email
Feb 2, 2006
1:38 pm
15930
... I wouldn't say it's dangerous, it's just that it adds more complexity to the system. Things can break easily after refactorings because refactorings don't...
Jason Rogers
jacaetev
Offline Send Email
Feb 2, 2006
2:11 pm
15931
Note: J2ME is my job, Java 3D is my hobbie. Well, I worked a litlle with the J2MEUnit, it resolved my problems, but i'm still working in some other questions...
Brunno Silva
brunno.silva@...
Send Email
Feb 2, 2006
3:13 pm
15932
Since there seems to be an interest in RTTI, I think that the following will be of interest Using polymorphism design techniques eliminates all need for RTTI...
Robert Lucente
roberto_lucente
Offline Send Email
Feb 2, 2006
3:35 pm
15933
... That's true, but it's still something to be mindful of. And to be more specific, what is slow in reflection is look up, not invocation, so if you really...
Cédric Beust 
cbeust
Offline Send Email
Feb 2, 2006
3:55 pm
15934
... You'll have to fill me in on what you mean by "sensorial capacity". I have some experience with Java3D. The approach that worked the best is similar to...
David Saff
dsaff
Offline Send Email
Feb 2, 2006
4:26 pm
15935
Thanks - honestly the idea is stolen from PMD. Its what they use to replace attributes (in Java 1.4) so you can supress individual warnings. I bet that you...
Mark Levison
marklevison
Offline Send Email
Feb 2, 2006
5:28 pm
15936
... Who needs training wheels? :) ... That's why we have tests. ... Not dangerous: we don't worry about the performance overhead of invoking methods or...
J. B. Rainsberger
nails762
Offline Send Email
Feb 3, 2006
1:22 am
15937
... You'd think that would be a big issue, but no--even well-known TDD practitioners pooh-pooh it. -- J. B. (Joe) Rainsberger :: http://www.jbrains.info Your...
J. B. Rainsberger
nails762
Offline Send Email
Feb 3, 2006
2:06 am
15938
... Really? How does Adapter do this? Specifically, I was working in an area where there were a number of rule methods, like boolean isReadyToStart(); boolean...
J. B. Rainsberger
nails762
Offline Send Email
Feb 3, 2006
2:20 am
15939
... No, that's why we have static typing. Besides, *you* have tests. Not everybody does. If I have to choose between "tests" and "tests and static typing", I...
Cédric Beust 
cbeust
Offline Send Email
Feb 3, 2006
4:47 am
Messages 15910 - 15939 of 22044   Oldest  |  < Older  |  Newer >  |  Newest
Advanced
Add to My Yahoo!      XML What's This?

Copyright © 2009 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines - Help