Exemplo n.º 1
0
        [SetUp] public void SetUp()
        {
            _core = new TestCore();
            _storage = _core.ResourceStore;

            CreateNecessaryResources();

            _registry = _core.FilterRegistry as FilterRegistry;
            _engine = _core.FilterEngine as FilterEngine;
            _wsManager = _core.WorkspaceManager;
            _unreads = _core.UnreadManager as UnreadManager;
            _mockResourceTabProvider = _core.GetComponentInstanceOfType( typeof(MockResourceTabProvider) ) as MockResourceTabProvider;
            _unreads.RegisterUnreadCountProvider( FilterManagerProps.ViewResName, new ViewUnreadCountProvider() );
        }
Exemplo n.º 2
0
        [SetUp] public void SetUp()
        {
            _core    = new TestCore();
            _storage = Core.ResourceStore;

            _storage.ResourceTypes.Register("Folder", "Name");
            _storage.ResourceTypes.Register("Email", "Name");
            _storage.ResourceTypes.Register("Person", "Name");
            _propFolder = _storage.PropTypes.Register("Folder", PropDataType.Link,
                                                      PropTypeFlags.CountUnread | PropTypeFlags.DirectedLink);

            _folder = _storage.NewResource("Folder");

            _wsManager = _core.WorkspaceManager;

            MockResourceTabProvider resourceTabProvider = (MockResourceTabProvider)_core.GetComponentInstanceOfType(typeof(MockResourceTabProvider));

            resourceTabProvider.SetResourceTab("Email", "Email");

            _unreadManager = _core.UnreadManager as UnreadManager;
            _propUnread    = Core.Props.IsUnread;
            _propSize      = _storage.PropTypes.Register("Size", PropDataType.Int);
        }