Goal setting
Each year, people will make new year resolutions for the next year. How can you set goals that will succeed the next year?
Tips for Software Developers
Each year, people will make new year resolutions for the next year. How can you set goals that will succeed the next year?
With keeping up the quality of your code comes writing unit tests. In its origin, a unit test tests the behavior of a method of a certain class. People tent to fall into writing more integration of system tests, where they test several components at once. Unit tests then become very hard to maintain. What does a good unit test consist of and what do we test?
Events in C# use the observer pattern, where an observer can subscribe itself to event generated by a subject. Within C# the observer can subscribe itself multiple times to the subject. When the subject fires the event, the observer gets multiple events.
The best way to prevent is to be keen on the life-cycle of your events; subscribe at the right place at an event en un-subscribe from the event also at the right place. How can we have a defensive mechanism, that prevents us subscribing multiple times at an event?
The software we write, most of the times depend on third-party libraries. Take for example Log4Net or a device driver. The problem in many projects is that the third-library libraries are much interwoven with the production code.
Herein lies a number of problems:
Uncle Bob states in his clean architecture that within a good design, the whole application isn’t aware of these third-party libraries. Think of a plug-in like ReSharper. At Visual Studio they didn’t have to change anything in their code to support the ReSharper plugin. Only the plugin knows about the existent of the other part of the software.
How can we create such an isolation and separate our libraries from our main architecture?