Entries from February 2009

Constructor Injection vs. Setter Injection

February 19th, 2009 · 31 Comments

by Miško Hevery There seems to be two camps in dependency-injection: (1) The constructor-injection camp and (2) the setter-injection camp. Historically the setter-injection camp come from spring, whereas constructor-injection camp are from pico-container and GUICE. But lets leave the history behind and explore the differences in the strategies. Setter-Injection The basic-ideas is that you have a no argument-constructor which creates [...]

Tags: Uncategorized

To Assert or Not To Assert

February 9th, 2009 · 31 Comments

by Miško Hevery Some of the strongest objections I get from people is on my stance on what I call “defensive programming”. You know all those asserts you sprinkle your code with. I have a special hate relationship against null checking. But let me explain. At first, people wrote code, and spend a lot of time debugging. Than someone came up [...]

Tags: Uncategorized

How to run FlexUnit in a continuous build

February 1st, 2009 · 5 Comments

So you have a flash or Flex code with lots of unit-tests. That is great, but how do you get them running in a continuous build? Sure you can run the tests manually, but this only gives you a visual green or red bar, what you really want is a X-Unit XML file so that [...]

Tags: Uncategorized