flow.
"Flow is a condition of deep, nearly meditative involvement." - Tom DeMarco

NStub Beta Released!

Friday, May 11, 2007 11:39 PM
Well, despite CodePlex's best efforts, I finally managed to get a beta of NStub out.  I've been working on NStub for quite some time and but I've finally gotten around to completing it.  If you're not familiar with NStub, basically it's a test code stub generator for legacy assemblies.  You point it at any .NET assembly and it will create a fully compiling C# project with a class file for every type found in the assembly which contains a method for every method found in the original type.  The catch is that "Test" is appended to both the class and the method and the methods are directed with NUnit test attributes.  So MyClass.MyMethod() becomes MyClassTest.MyMethodTest(), get it?  This is intended for classic fine grained unit testing where you test every single method individually. 

To be honest, I started this project before I caught on to the whole idea of Test Driven Development so it really isn't too much of use to me now since it's essentially a code generator for post testing.  However, I decided to go ahead and finish it in hopes that it may be of help to someone else out there.  That said, I don't plan to do too much additional work on it immediately but when you find bugs--and you will--feel free to drop them in the project's Trac page and I'll be happy to put a fix out.  Also, new features will be driven by the community at this point so if you have any ideas, or you want to contribute, feel free to drop me a line either here or over on the project page.

Enjoy!

kick it on DotNetKicks.com

Feedback

# re: NStub Beta Released!

Nice work! I like the way you coded it too, simple and to the point (and you took the Code DOM challenge!) I like the way you built the project file using the references out of the DLL so everything resolves straight up - good work!
I have done similar things in the past but never anything I would want exposed to the public (ahem)... I am also now more focused on TDD but its still common to come accross those legacy apps and NStub looks like a good way to get the ball rolling on getting some sort of testing for the old apps. 5/21/2007 6:33 PM | Paul Kohler

# re: NStub Beta Released!

Hi Paul,

Thank you so much for the kind comment. In reference to the to CodeDOM challenge, :), I actually started out using a simple TextWriter but then I discovered the whole CodeDOM idea. You're definitely right, it was a quite a challenge but it resulted in less code in the end and even left me flexible enough to easily support additional languages if I chose in the future.

Glad to hear that you're getting into TDD as well, I'm definitely making point to try and write as much new code using TDD as possible. But, hopefully when it comes time to start supporting that legacy code NStub might be playing a part in it.

Thanks again for the comment, and I really hope you enjoy using NStub. Don't hesitate to drop me an email if you have suggestions or criticisms, I'd love to hear from you!

Jeremy 5/22/2007 4:44 PM | Jeremy

Post a comment





 

Please add 8 and 1 and type the answer here: