public void CanGetSortToolbarPlugIns()
        {
            IList <ToolbarPluginAttribute> plugIns = new List <ToolbarPluginAttribute>(finder.GetPlugins <ToolbarPluginAttribute>());

            Assert.That(plugIns.Count(), Is.EqualTo(3));

            ToolbarPluginAttribute plugin1 = plugIns[0];

            Assert.AreEqual("peace", plugin1.Name);
            Assert.AreEqual("Don't worry be happy", plugin1.Title);

            ToolbarPluginAttribute plugin2 = plugIns[1];

            Assert.AreEqual("panic", plugin2.Name);
            Assert.AreEqual("Worry we're coming", plugin2.Title);
        }
Exemple #2
0
		private void AddPlugin(ContentItem start, ContentItem root, ToolbarPluginAttribute plugin, Control command)
		{
			plugin.AddTo(command, new PluginContext(Page.GetSelection(), start, root,
			                                        ControlPanelState.Visible,
			                                        Engine, new HttpContextWrapper(Context)));
		}
 private void AddPlugin(ContentItem start, ContentItem root, ToolbarPluginAttribute plugin, Control command)
 {
     plugin.AddTo(command, new PluginContext(Page.GetSelection(), start, root,
                                             ControlPanelState.Visible,
                                             Engine, new HttpContextWrapper(Context)));
 }
 private void AddPlugin(ContentItem start, ContentItem root, ToolbarPluginAttribute plugin, Control command)
 {
     plugin.AddTo(command, new PluginContext(Selection.SelectedItem, null, start, root,
                                             ControlPanelState.Visible,
                                             Engine.ManagementPaths));
 }