public void GetProxyModuleTwiceReturnsSameProxyModule()
        {
            OnDemandProxyModule.Clear();
            var proxyModule = OnDemandProxyModule.GetProxyModule();

            Assert.That(proxyModule, Is.Not.Null);
            Assert.That(OnDemandProxyModule.GetProxyModule(), Is.SameAs(proxyModule));
        }
        public void GetProxyModuleCreatesProxyModuleFromFactory()
        {
            OnDemandProxyModule.Clear();
            bool called = false;

            ProxyFooPolicies.ProxyModuleFactory = () =>
            {
                called = true;
                return(ProxyFooPolicies.DefaultProxyModuleFactory());
            };
            Assert.That(OnDemandProxyModule.GetProxyModule(), Is.Not.Null);
            Assert.That(called);
            ProxyFooPolicies.ProxyModuleFactory = ProxyFooPolicies.DefaultProxyModuleFactory;
        }
 public void GetProxyModuleReturnsProxyModule()
 {
     OnDemandProxyModule.Clear();
     Assert.That(OnDemandProxyModule.GetProxyModule(), Is.Not.Null);
 }