public void it_should_notify_when_project_added() { int added = VSConstants.S_OK; solutionEventSink.OnAfterOpenProject(someHierarchy, added); solutionOpenedObserver.Messages.Should().BeEmpty(); solutionClosingObserver.Messages.Should().BeEmpty(); projectAddedObserver.Messages.Should().HaveCount(1); projectAddedObserver.Messages.Single().Value.Value.Hierarchy.Should().Be(someHierarchy); projectRemovingObserver.Messages.Should().BeEmpty(); }
int IVsSolutionEvents.OnAfterOpenProject(IVsHierarchy pHierarchy, int fAdded) { IVsSolutionEvents hostService = (IVsSolutionEvents)GetService(typeof(IHostService)); return(hostService.OnAfterOpenProject(pHierarchy, fAdded)); }