How would type errors be detected while creating mocks in a dynamic language?
The problem occurs while doing TDD. After a couple of test pass, the return types of some class/module change. In a statically typed programming language, if a previous mocked object was used in the tests of some other class and was not modified to reflect the type change, then compilation errors will occur.
Is it okay to mock multiple objects in one class?
For developers with extensive experience using mocks, is it okay to mock multiple objects in one class (ie satisfy multiple interfaces) or is this not recommended?
should you always enter a bug in a bug tracking system [duplicate]
Possible Duplicate:
Should developers enter bugs into the bug tracking system?
Should I log trivial fixes?
Why is it often said that the test cases need to be made before we start coding? [duplicate]
This question already has answers here: What are the disadvantages of writing code before writing unit tests? (9 answers) Closed 11 years ago. Why is it often said that the test cases need to be made before we start coding? What are its pros and what the cons if we don’t listen to this advice? […]
How much to test in TDD?
I am newbie to TDD (writing first project following TDD practices).
How much to test in TDD?
I am newbie to TDD (writing first project following TDD practices).
How do we make unit tests run fast?
We have reached the point in our project where we have almost a thousand tests and people have stopped bothering with running them before doing a check in because it takes so long. At best they run the tests that are relevant to the piece of code that they changed and at worst they simply check it in without testing.
Unit Test Friendly Domain Driven Design
Many of the readings I’ve done on DDD, both in books and online, seem to represent code that, often times, is difficult or impossible to unit test. For example, there are numerous samples with static factories, calls to concrete domain classes and static extension methods (in C# samples only). I find it frustrating and taxing to have to constantly re-evaluate the code to make it testable in my mind.
Test driven development when implementing a flexible length list
According to the commonly used TDD strategy, to implement something, you write a test that fail the code first, write the simplest code, refactor, and then repeat. I am trying to imagine this scenario with implementing a flexible length list (e.g. List<T>
in .net.
How should you TDD a Yahtzee game?
Let’s say you’re writing a Yahtzee game TDD style. You want to test the part of the code that determines whether or not a set of five die rolls is a full house. As far as I know, when doing TDD, you follow these principles: