Exemplo n.º 1
0
        public void can_create_screen_for_a_test()
        {
            var test      = new Test("the test");
            var subject   = _objectLocator.BuildSubject(test).ShouldBeOfType <ScreenLocator <Test> >();
            var presenter = subject.CreateScreen(factory).ShouldBeOfType <TestScreen>();

            presenter.Test.ShouldBeTheSameAs(test);
        }
Exemplo n.º 2
0
        public void Handle(DeleteTestMessage message)
        {
            IScreenLocator screenLocator = _screenObjectLocator.BuildSubject(message.Test);
            IScreen        screen        = findScreenMatchingSubject(screenLocator);

            if (screen == null)
            {
                return;
            }

            Close(screen);
        }