Archives for the 'TDD' Category
Stop Designing for Testability – Revisited
I just received an email about a comment on my article on Code Project, Stop Designing for Testability. After nearly 3 years it is still getting comments.
The article is about the tension and balance between TDD/DI and OOD.
While looking at the article I am excited to see how much we have progressed, with the AAA […]
Unit Tests and Developers under Pressure
In TechEd 2008 David Platt interviewed Roy about the future of TDD. You should really view the Tech-Talk as Dave is really funny, although he does miss the number of possible TLA’s (which he recursively defines as a TLA = Three Letter Acronym) by 300.
About 5 minutes into the session David asks a key question: […]
The myth of integration tests
The question of what exactly is a unit test, is one that keeps on plaguing us as a community. I have heard many developers say “oh, no need to test that - its an integration test”.
Well - what is a unit test? and what is an integration test? Guess what: One programmer’s unit test is […]
Unit Testing Collections
I have written about Lowering the friction of Unit testing, and how using Aspect Faking we can lower the friction of testing collections
The problem
Unit testing collections can be a bit tricky. Lets see some code and unit test this Sum() method:
public List<Salary> Salaries { get; }
public float Sum()
{
float total = 0;
[…]
Lowering the friction of Unit testing
At Typemock we have been learning allot about our customers lately and understanding where the friction is so that we can make unit testing even easier and maintainable.
What we are succeeding in doing is to lower the density of the tests (this means less code in each test) and raise the test resilient (this […]
Ruby Style Isolating - Aspect Faking
I have talked in the past about Ruby Style Isolating (Dynamically Typed), now it is part of the AAA syntax.
The big value of this feature is that you don’t have to inherit a type in order to replace it with a fake, the downfall of this is that when you refactor your code, you […]
Future of Unit Testing and Economics
Euan Garden managed the PDC 2008 Panel Session on the Future of Unit Testing, and Andrew has made a short summary.
Unit Test => (Automated) Developers Tests
An interesting thought that come from listening to this panel is that there is a confusion about what unit tests are and I agree that we should really call it […]
Mocking frameworks - dream feature
There are some developers SHOUTING, that mocking static and non-virtual methods is a big No-No. Roy, is calling them dogmatic.
Come on guys, the most requested feature from Rhino.Mocks is the ability to mock non-virtual and static members, and Oren has even implemented these when possible (MarshalByRef Objects). I am sure that if it was easy, […]
Interesting Unit Testing Survay
According to a Telerik Survey (brought to me by Avi Kaye) Unit Testing is still not mainstream.
I am not sure how many people voted, and although the result might surprise some of you, these results confirm what I think about the implementation of automated unit tests.
Unit testing is still quite difficult and there is a […]
Understanding Mock Objects - Better Design
Azam has written a post about Ben Hall’s article “Beginning to Mock Using Rhino Mocks and MbUnit“. The logic in the example is a method that returns an image of the sun in the day and the moon at night. In both Azam’s and Ben Halls examples, the GetImage()method returns the image name
public string GetImage()
{
[…]