An Introduction to Reactive Programming with RxJava – Part 1

Nowadays, the term reactive programming is trending. Libraries and frameworks in various programming languages are emerging. Blog posts, articles and presentations about reactive programming are being created. Big companies, such as Facebook, SoundCloud, Microsoft, and Netflix, are supporting and using this concept. So we, as programmers, are starting to wonder about it. Why are people […]

Continue Reading

Understanding behavior-driven development

Test-driven development (TDD) is a software development process originated from Extreme Programming (XP) invented by Kent Beck, which relies on the repetition of a number of short and continuous development cycles. TDD can lead to more modularized, flexible, and extensible code; the early and frequent nature of the testing helps to catch defects early in […]

Continue Reading

Using Test Doubles with Unit Tests – PART 2

Getting back to the example, using the same repository and test that we outlined previously, we now convert that test to use a mock created by Moq instead of the repository stub. Listing below demonstrates how the code looks. using System; using System.Data.SqlClient; using Microsoft.Practices.Unity; using Microsoft.VisualStudio.TestTools.UnitTesting; using Moq; namespace CodeSamples.Ch05_ClassMocking.Listing04 { public class MockingExample […]

Continue Reading

Continuously Integrate

HE BUILD AS A “BIG BANG” EVENT in project development is dead. The architect, whether an application or enterprise architect, should promote and encourage the use of continuous integration methods and tools for every project. The term continuous integration (CI) was first coined by Martin Fowler in a design pattern. CI refers to a set […]

Continue Reading

Mocks aren’t stubs (Just a quick review)

I know that Martin Fowler has written about this extensively, but I wanted to write a concise version, since this point seems to bear reiterating from time to time. Mocks aren’t stubs. Specifically, I recommend against setting an expectation on a method (“mocking” it) when you really want to simulate a specific response from that […]

Continue Reading