Programming

C# Implicitly Scoped Using Statements

Posted on

This is a little gold nugget that is coming in C# 8 – implicitly scoped using statements. On a simple level, it means that when you consume an IDisposable class your previously explicitly scoped using statements: using (var connection = GetConnection()) { // Use the connection, it will be disposed of at the end } […]

Programming

C# Interfaces: Default Implementations

Posted on

The C# 8.0 announcement included a note on default implementations of interface members. If you’ve been programming for long enough, this might make you a little nervous at first thanks to the hangovers of multiple inheritance. Before you chuck out this idea, though, let’s look at it from a different perspective. I’m going to talk […]

Programming

NUnit Exception Occurred While Test Discoverer Was Loading Tests

Posted on

If you are using NUnit 3+ with the handy test adapter that shows the tests in the Visual Studio Test Explorer, you might come across an issue loading the tests: An exception occurred while test discoverer ‘NUnit3TestDiscoverer’ was loading tests. Exception: Could not load file or assembly ‘nunit.engine, Version=3.5.0.0, Culture=neutral, PublicKeyToken=2638cd05610744eb’ or one of its […]

Programming

Code Organisation and Junk

Posted on

Code organisation feels like hard work at times; but there are some mental tricks you can apply to help break the inertia. This article contains a couple of ideas that will help you get moving when you don’t know where to start. I’m not going to go through the steps you need to take to […]