tdd

Recursos de programación de tdd
After the two previous posts (Clarifying conditional logic and Replacing conditional with polymorphism using multimethods), I had this version of the code: that was being used from the gilded-rose.core name space: Then I started introducing the new conjured items functionality using TDD. These are the new tests for conjured items: and these is the resulting code of the gilded-rose.item-quality name space: Notice the change in the update multimethod dispatch function. Now instead of being :name...
Few weeks ago I attended to the first Socrates conference organized in spain (In Tenerife)
Web
19-03-2015
http , tdd
I've just watched this great live-demo of using TDD to code a UI by Toran Billups: TDD by example - por Garajeando
Yesterday we had a coding dojo in Clojure Developers Barcelona meetup. We practiced together doing the Mars Rover kata. I had already done this kata in Java and C++ before (several times) using the state pattern to eliminate all the conditionals on the rover direction and the command pattern to decouple the translation from the messages sent to the rover into commands acting on it. As usual I used a mix of TDD and work on the REPL to code this Clojure version. To document the process I committed...
Two weeks ago I facilitated an introduction to TDD in a Scala Developers Barcelona event. First, I gave a very short introductory talk about TDD, (these are the slides). After the talk, I coded a simple exercise to help the attendants get a feeling of the TDD flow. I tried to stress the importance of creating a list of examples first and choosing the next test so that the code could grow in small steps. I also talked about wishful programming, going from red to green quickly and the importance...
I've just done the Password validator kata in Clojure. It's a basic kata that, in my opinion, is very useful to think about how we choose the next test so that it helps us grow the code in small steps. In this kata you have to validate a password. The conditions that it has to fulfill to be valid are: It should have more than 6 charactersIt should contain at least one upper case characterIt should contain at least one lower case characterIt should contain at least one underscoreIt should contai...
Si, ya se, todo el mundo suele comentar que los pilares del desarrollo de software ágil son tres:La cultura, principios y valoresLos métodos y artefactos de gestión (liturgias y procesos correspondientes a scrum, kanban, etc.)Las prácticas técnicas y la búsqueda de la excelencia técnica (Pair programing, TDD, collective code ownership, Integración continua, etc.)Pero tengo la sensación que para un desarrollo de software que aporte valor a los clientes y que sea sostenido en el tiempo, principalm...
I've just done the LCD Digits kata in Clojure. In this kata you have to create an LCD string representation of an integer value using a 3x3 grid of space, underscore, and pipe characters for each digit. Each digit is shown below (using a dot instead of a space) ._. ... ._. ._. ... ._. ._. ._. ._. ._.|.| ..| ._| ._| |_| |_. |_. ..| |_| |_||_| ..| |_. ._| ..| ._| |_| ..| |_| ..|Example: 910._. ... ._.|_| ..| |.|..| ..| |_|These are the tests...
I've just dome the Happy Numbers kata in Clojure. It's a simple kata that can be a lot of fun. I used a mix of TDD and REPL-driven development to code it. These are the resulting tests in Midje: and this is the code: To document the process I commited the code after every passing test and every refactoring. I also commited the REPL history. You can find the commits step by step hereand the code in this repository in GitHub. I used memoize to avoid repeated computations. In the next days I will...
Álvaro and I have been pairing lately to do a subset of the Bank Account kata that Sandro Mancuso proposed as an exercise in his Crafting Code course. We had to write and make the following acceptance test pass using Outside-In TDD: Given a client makes a deposit of 1000.00 on 01/04/2014And a withdrawal of 100.00 on 02/04/2014And a deposit of 500.00 on 10/04/2014When she prints her bank statementThen she would seeDATE | AMOUNT | BALANCE10/04/2014 | 500.00 | 1400.0002/04/2014 | -100.00 | 900.000...