This project uses Source Generation to generate an interface and a Proxy class for classes. This makes it possible to wrap external classes which do not have an interface, in a Proxy class which makes it easier to Mock and use Dependency Injection.
If the Interface with the proxy attribute is defined in a file without a namespace. this results in a build error as the generated
e.g.
using Akka.Actor;
//namespace ConsoleApp66; <- no namespace
[ProxyInterfaceGenerator.Proxy(typeof(LocalActorRefProvider))]
public partial interface ILocalActorRefProvider
{
}
code ends up looking like so:
namespace. /*nothing here*/
{
// all the proxy stuff
}
If the Interface with the proxy attribute is defined in a file without a namespace. this results in a build error as the generated e.g.
code ends up looking like so: