I'm writing unit tests (MSTest) in C# 6.0 and I noticed something strange in the way the compiler handles string interpolation in attributes.
Why does this work:
[TestCategory(nameof(MyClass) + "-UnitTest")]
When this doesn't?
[TestCategory($"{nameof(MyClass)}-UnitTest")]
Ignoring the fact that this might not be a great way to categorize my tests; I'm curious why the compiler allows one and not the other.