sfeldman.NET
.NET, code, personal thoughts
-
TODOs are not forgotten
We are using Hudson as a build server, and one of the lasts steps that were taken is to mark a build as ‘unstable’ when we pass a certain number of TODO comments in our code (an arbitrary number). While I am not a 100% sold on a number, I think it’s a good way of insuring things are not just marked and forgotten. Actually, we are not even tracking TODOs, but BROKEN_WINDOW comments, as those are definitely bad. Failing on HACK is another possibility. Visualization plays a significant role in my case (interpretation of things based on visualization), and here how it looks (green is all good, yellow is all passed, but number of comments has exceeded the limit).
-
Gallio Warning Output
Today I was trying to figure out how to access output Gallio is using to render a warning message. According to this, the Assert.Warning was replaced by TestLog.Warning.WriteLine. But for some reason that is not doing the job. Has anyone encountered similar problem?
-
NHibernate Profiler
Recently I had to update our domain model and it required some NHibernate profiling. I have installed trial version of NHibernate Profiler, and it rocked. The fact that it was not only able to show what was going on, but also give suggestions how to improve NHibernate usage just rocked (unlimited records returned).
-
Wix Product Version with Build Script
Our projects are deployed with MSIs. Each MSI file is appended with the product version number (regular staff – major, minor, build number, revision number).
-
MSMQ With Files Larger Than 10MB?
Update 2009-09-11: I was playing with the sample provided in two comments, and has run into issue with chunking binding. See thread: http://code.msdn.microsoft.com/msmqpluswcf/Thread/View.aspx?ThreadId=2265
-
Sumsing Turbo 3000 Xi Multitask
Related to the recent post comments – this is the *REAL* thing :D
-
Moq – ToString() Method Pitfall
I was working on some code today, when run into a pitfall with Moq. This was probably my misreading of documentation.
-
Warning – Best Practices
According to the wikipedia definition, best practice is
-
Disjunction and Conjunction in NHibernate
Criteria involving multiple ORs and ANDs can quickly become ugly. David showed how some of our code became more readable by using a feature to join multiple ICriterion-s instead of using Restrictions class (as well as how to quickly leverage expressions to get away from using property names, and allow better refactoring by replacing strings with compile-able code).
-
Sending Emails with no SMTP
I ran into a problem once in a QA environment, and it was unpleasant to handle. Amr ElGarhy has showed a way “baked into” .NET how to overcome issues similar to the one I had – write emails straight into file system. Solutions is elegant and done through configuration file.