public void Setup() { _fake = new FakeMaker(); // Arrange: create a page tree _root = FakePage.Create("root"); _start = FakePage .Create("Start") .ChildOf(_root) .AsStartPage(); FakePage .Create("AboutUs") .ChildOf(_root); FakePage .Create <CustomPageData>("OtherPage") .ChildOf(_root) .HiddenFromMenu(); FakePage .Create("Contact") .ChildOf(_root); FakePage .Create("Our sub page") .ChildOf(_start); // Arrange: add the entire page tree to the episerver repository. _fake.AddToRepository(_root); }
private void SetupFakes() { _fake = new FakeMaker(); EPi.Extensions.SingletonPage.Extensions.InjectedContentLoader = new Injected <IContentLoader>(_fake.ContentRepository); _fakeCache = new FakeCache(); EPi.Extensions.SingletonPage.Extensions.InjectedCache = new Injected <IContentReferenceCache>(_fakeCache); }
public void Setup() { _fake = new FakeMaker(); }
private void SetupFakes() { _fake = new FakeMaker(); Extensions.SingletonPage.Extensions.InjectedContentLoader = new Injected<IContentLoader>(_fake.ContentRepository); _fakeCache = new FakeCache(); Extensions.SingletonPage.Extensions.InjectedCache = new Injected<IContentReferenceCache>(_fakeCache); }