public void Configure(BehaviorGraph graph) { var diagnosticGraph = new DiagnosticGraph(); diagnosticGraph.Add(graph.ApplicationAssembly); diagnosticGraph.Add(typeof(IPackageFacility).Assembly); PackageRegistry.PackageAssemblies.Each(diagnosticGraph.Add); diagnosticGraph.Groups().SelectMany(x => x.Chains).Each(graph.AddChain); graph.Services.AddService(diagnosticGraph); }
public DiagnosticGroupsMenuTag(DiagnosticGraph groups, ICurrentHttpRequest httpRequest) : base("ul") { AddClass("dropdown-menu"); Attr("role", "menu"); Attr("aria-labelledby", "groups"); groups.Groups().OrderBy(x => x.Title).Each(group => { var li = Add("li").Attr("role", "presentation"); li.Add("a") .Attr("role", "menuitem") .Attr("tabindex", "-1") .Attr("href", httpRequest.ToFullUrl(group.GetDefaultUrl())) .Text(group.Title).Attr("title", group.Description); }); }
public void current_context_and_group_with_normal_chain() { var currentChain = MockRepository.GenerateMock<ICurrentChain>(); currentChain.Stub(x => x.OriginatingChain).Return(new BehaviorChain()); var graph = new DiagnosticGraph(); graph.Add(typeof(DiagnosticChain).Assembly); var request = new InMemoryFubuRequest(); request.Set(new GroupRequest{Name = "FubuMVC.Diagnostics"}); var context = new DiagnosticContext(currentChain, request, graph); context.CurrentChain().ShouldBeNull(); context.CurrentGroup().Name.ShouldEqual("FubuMVC.Diagnostics"); }
public DiagnosticContext(ICurrentChain currentChain, IFubuRequest fubuRequest, DiagnosticGraph graph) { _currentChain = currentChain; _fubuRequest = fubuRequest; _graph = graph; }
public GroupEndpoint(DiagnosticGraph graph, ICurrentHttpRequest httpRequest) { _graph = graph; _httpRequest = httpRequest; }
public DashboardFubuDiagnostics(DiagnosticGraph graph, ICurrentHttpRequest httpRequest) { _graph = graph; _httpRequest = httpRequest; }