public void should_remove_chain_from_caches() { var graph = new FubuRegistry(x => { x.Applies.ToThisAssembly(); x.Actions.IncludeClassesSuffixedWithController(); }).BuildGraph(); var chain = graph.ChainsFor(typeof(MyRequestModel)).First(); graph.RemoveChain(chain); graph .ChainsFor(typeof(MyRequestModel)) .ShouldNotContain(chain); }
public void should_remove_chain() { var graph = new FubuRegistry(x => { x.Applies.ToThisAssembly(); x.Actions.IncludeClassesSuffixedWithController(); x.Routes.HomeIs <MyHomeController>(c => c.ThisIsHome()); }).BuildGraph(); var chain = graph.FindHomeChain(); graph.RemoveChain(chain); graph .Behaviors .ShouldNotContain(chain); }