Dealing with the fallout in failing unit tests from a code merge is one of the most frustrating tasks in software development. And as one of a (very) small number of developers on our team that believes in unit testing, it fell to me to determine the cause of multiple instances of the structuremap exception code 207 error.
As it turned out, the culprit was a tactic I’ve used in the past to work with code that only works with a specific version of an assembly–the binding redirect. When the same person is in charge of upgrading dependencies, this tends not to be an issue because if they’ve used binding redirects, they know it’s necessary to update them when dependencies are upgraded. In this case, the dependencies were upgraded and the redirects were not. As a result, StructureMap tried to find a specific version of an assembly that was no longer available and threw exception code 207 when it failed.