Example #1
0
        public static void SiteMapChildNode(Page p)
        {
            PokerSiteMapPath      smp   = new PokerSiteMapPath();
            SiteMapNodeCollection myCol = smp.Provider.GetChildNodes(smp.Provider.RootNode);

            Assert.AreEqual(1, myCol.Count, "SiteMapChildNode#1");
        }
Example #2
0
        public static void InitializeItemCurrent(Page p)
        {
            PokerSiteMapPath smp = new PokerSiteMapPath();
            SiteMapNodeItem  I   = new SiteMapNodeItem(1, SiteMapNodeItemType.Current);

            smp.CurrentNodeStyle.BackColor = Color.Red;
            smp.NodeStyle.BorderColor      = Color.Red;
            smp.DoCreateControlHierarchy();
            I.SiteMapNode = smp.Provider.CurrentNode;
            smp.InitilizeItems(I);

            Assert.AreEqual(1, I.Controls.Count, "InitializeItem#1");
            Assert.AreEqual(typeof(Literal), I.Controls[0].GetType(), "InitializeItem#2");
            Assert.AreEqual(Color.Red, I.BackColor, "InitializeItem#3");
            Assert.AreEqual(Color.Red, I.BorderColor, "InitializeItem#4");

            I.Controls.Clear();
            smp.RenderCurrentNodeAsLink = true;
            smp.InitilizeItems(I);

            Assert.AreEqual(1, I.Controls.Count, "InitializeItem#5");
            Assert.AreEqual(typeof(HyperLink), I.Controls[0].GetType(), "InitializeItem#6");
            Assert.AreEqual(Color.Red, I.BackColor, "InitializeItem#7");
            Assert.AreEqual(Color.Red, I.BorderColor, "InitializeItem#8");
        }
Example #3
0
        public void SiteMapPath_ChangeProperties()
        {
            PokerSiteMapPath p = new PokerSiteMapPath();

            p.ShowToolTips = false;
            Assert.IsFalse(p.ShowToolTips, "ShowToolTips");

            Style currentNodeStyle = new Style();

            p.CurrentNodeStyle.ForeColor = Color.AliceBlue;
            Assert.AreEqual(Color.AliceBlue, p.CurrentNodeStyle.ForeColor, "CurrentNodeStyle");

            Style NodeStyle = new Style();

            p.NodeStyle.BackColor = Color.Aqua;
            Assert.AreEqual(Color.Aqua, p.NodeStyle.BackColor, "NodeStyle");

            p.PathDirection = PathDirection.CurrentToRoot;
            Assert.AreEqual(PathDirection.CurrentToRoot, p.PathDirection, "PathDirection");

            p.PathSeparator = " - ";
            Assert.AreEqual(" - ", p.PathSeparator, "PathSeparator");

            Style RootNodeStyle = new Style();

            p.RootNodeStyle.BackColor = Color.Red;
            Assert.IsFalse(p.RootNodeStyle.IsEmpty, "RootNodeStyle#1");
            Assert.AreEqual(Color.Red, p.RootNodeStyle.BackColor, "RootNodeStyle#2");

            p.ParentLevelsDisplayed = 2;
            Assert.AreEqual(2, p.ParentLevelsDisplayed, "ParentLevelsDisplayed");

            p.RenderCurrentNodeAsLink = true;
            Assert.IsTrue(p.RenderCurrentNodeAsLink, "RenderCurrentNodeAsLink");

            p.SiteMapProvider = "test";
            Assert.AreEqual("test", p.SiteMapProvider, "SiteMapProvider");

            p.SkipLinkText = "test";
            Assert.AreEqual("test", p.SkipLinkText, "Skip Navigation Links");

            //programmatically create template
            MyWebControl.Image myImage = new MyWebControl.Image();
            myImage.ImageUrl = "myimage.jpg";
            ImageTemplate rootNodeImageTemplate = new ImageTemplate();

            rootNodeImageTemplate.MyImage = myImage;
            // end create template image
            p.RootNodeTemplate = rootNodeImageTemplate;
            Assert.IsNotNull(p.RootNodeTemplate, "RootNodeTemplate");
            Assert.AreEqual(rootNodeImageTemplate, p.RootNodeTemplate, "RootNodeTemplate");

            p.NodeTemplate = rootNodeImageTemplate;
            Assert.IsNotNull(p.NodeTemplate, "NodeTemplate");
            Assert.AreEqual(rootNodeImageTemplate, p.NodeTemplate, "NodeTemplate");

            p.CurrentNodeTemplate = rootNodeImageTemplate;
            Assert.IsNotNull(p.CurrentNodeTemplate, "RootNodeTemplate");
            Assert.AreEqual(rootNodeImageTemplate, p.CurrentNodeTemplate, "RootNodeTemplate");
        }
Example #4
0
        public void Events(Page p)
        {
            PokerSiteMapPath smp = new PokerSiteMapPath();

            ResetEvents();
            smp.DataBinding   += new EventHandler(DataBindingHandler);
            smp.ItemDataBound += new SiteMapNodeItemEventHandler(ItemDataBoundHandler);
            smp.ItemCreated   += new SiteMapNodeItemEventHandler(ItemCreatedHandler);

            Assert.AreEqual(false, DataBinding, "BeforeDataBinding");
            smp.DoOnDataBinding(new EventArgs());
            Assert.AreEqual(true, DataBinding, "AfterDataBinding");

            ResetEvents();
            Assert.AreEqual(false, ItemDataBounding, "BeforeItemDataBound");
            SiteMapNodeItem i = new SiteMapNodeItem(0, SiteMapNodeItemType.Root);

            smp.DoOnItemDataBound(new SiteMapNodeItemEventArgs(i));
            Assert.AreEqual(true, ItemDataBounding, "AfterItemDataBound");

            ResetEvents();
            SiteMapNodeItemEventArgs MyArgs = new SiteMapNodeItemEventArgs(new SiteMapNodeItem(0, SiteMapNodeItemType.Parent));

            Assert.AreEqual(false, ItemCreated, "BeforeItemCreated");
            smp.DoOnItemCteated(MyArgs);
            Assert.AreEqual(true, ItemCreated, "AfterItemCreated");
        }
Example #5
0
        public static void InitializeItemPathSeparator(Page p)
        {
            PokerSiteMapPath smp = new PokerSiteMapPath();
            SiteMapNodeItem  I   = new SiteMapNodeItem(0, SiteMapNodeItemType.PathSeparator);

            smp.PathSeparatorStyle.BorderColor = Color.Red;
            smp.InitilizeItems(I);
            Assert.AreEqual(1, I.Controls.Count, "InitializeItem#1");
            Assert.AreEqual(typeof(Literal), I.Controls[0].GetType(), "InitializeItem#2");
            Assert.AreEqual(Color.Red, I.BorderColor, "InitializeItem#3");
        }
Example #6
0
        public static void InitializeItemParent(Page p)
        {
            PokerSiteMapPath smp = new PokerSiteMapPath();
            SiteMapNodeItem  I   = new SiteMapNodeItem(0, SiteMapNodeItemType.Parent);

            smp.NodeStyle.BorderColor = Color.Red;
            smp.DoCreateControlHierarchy();
            I.SiteMapNode = smp.Provider.RootNode;
            smp.InitilizeItems(I);

            Assert.AreEqual(1, I.Controls.Count, "InitializeItem#1");
            Assert.AreEqual(typeof(HyperLink), I.Controls[0].GetType(), "InitializeItem#2");
            Assert.AreEqual(Color.Red, ((HyperLink)I.Controls[0]).ControlStyle.BorderColor, "InitializeItem#4");
        }
Example #7
0
        public static void InitializeItemTemplates(Page p)
        {
            PokerSiteMapPath smp = new PokerSiteMapPath();
            SiteMapNodeItem  I   = new SiteMapNodeItem(1, SiteMapNodeItemType.Current);

            smp.CurrentNodeTemplate        = new CompiledTemplateBuilder(templatebuilder);
            smp.CurrentNodeStyle.BackColor = Color.Red;
            smp.DoCreateControlHierarchy();
            I.SiteMapNode = smp.Provider.CurrentNode;
            smp.InitilizeItems(I);

            Assert.AreEqual(1, I.Controls.Count, "InitializeItem#1");
            Assert.AreEqual(typeof(TextBox), I.Controls[0].GetType(), "InitializeItem#2");
            Assert.AreEqual(Color.Red, I.BackColor, "InitializeItem#3");
        }
Example #8
0
        public static void DoTestStylesRender(Page p)
        {
            PokerSiteMapPath smp = new PokerSiteMapPath();

            smp.ControlStyle.BackColor       = Color.Red;
            smp.CurrentNodeStyle.BackColor   = Color.Pink;
            smp.NodeStyle.BorderColor        = Color.Purple;
            smp.PathSeparatorStyle.BackColor = Color.RoyalBlue;
            smp.RootNodeStyle.BackColor      = Color.Beige;
            LiteralControl lcb = new LiteralControl(HtmlDiff.BEGIN_TAG);
            LiteralControl lce = new LiteralControl(HtmlDiff.END_TAG);

            p.Form.Controls.Add(lcb);
            p.Form.Controls.Add(smp);
            p.Form.Controls.Add(lce);
        }
Example #9
0
        public void SiteMapPath_NullProperties()
        {
            PokerSiteMapPath p = new PokerSiteMapPath();

            p.ShowToolTips = false;
            Assert.IsFalse(p.ShowToolTips, "ShowToolTips");
            Assert.AreEqual(1, p.StateBag.Count, "NullProperties#1");
            p.PathDirection = PathDirection.CurrentToRoot;
            Assert.AreEqual(PathDirection.CurrentToRoot, p.PathDirection, "PathDirection");
            Assert.AreEqual(2, p.StateBag.Count, "NullProperties#2");
            p.PathSeparator = " - ";
            Assert.AreEqual(3, p.StateBag.Count, "NullProperties#3");
            p.SiteMapProvider = "test";
            Assert.AreEqual(4, p.StateBag.Count, "NullProperties#4");
            p.SkipLinkText = "test";
            Assert.AreEqual(5, p.StateBag.Count, "NullProperties#5");
            p.SkipLinkText = null;
        }
Example #10
0
        public void SiteMapPath_DefaultProperties()
        {
            PokerSiteMapPath p = new PokerSiteMapPath();

            Assert.IsTrue(p.CurrentNodeStyle.IsEmpty, "CurrentNodeStyle");
            Assert.IsNull(p.CurrentNodeTemplate, "CurrentNodeTemplate");
            Assert.IsTrue(p.NodeStyle.IsEmpty, "NodeStyle");
            Assert.IsNull(p.NodeTemplate, "NodeTemplate");
            Assert.AreEqual(-1, p.ParentLevelsDisplayed, "ParentLevelsDisplayed");
            Assert.AreEqual(PathDirection.RootToCurrent, p.PathDirection, "PathDirection");
            Assert.IsNull(p.PathSeparatorTemplate, "PathSeparatorTemplate");
            Assert.IsFalse(p.RenderCurrentNodeAsLink, "RenderCurrentNodeAsLink");
            Assert.IsTrue(p.RootNodeStyle.IsEmpty, "RootNodeStyle");
            Assert.IsNull(p.RootNodeTemplate, "RootNodeTemplate");
            Assert.IsTrue(p.ShowToolTips, "ShowToolTips");
            Assert.AreEqual("", p.SiteMapProvider, "SiteMapProvider");
            Assert.AreEqual("Skip Navigation Links", p.SkipLinkText, "Skip Navigation Links");
        }
Example #11
0
        public void SiteMapPath_ViewState()
        {
            PokerSiteMapPath p = new PokerSiteMapPath();

            p.ShowToolTips = false;
            Style currentNodeStyle = new Style();

            p.CurrentNodeStyle.ForeColor = Color.AliceBlue;
            Style NodeStyle = new Style();

            p.NodeStyle.BackColor = Color.Aqua;
            p.PathDirection       = PathDirection.CurrentToRoot;
            Assert.AreEqual(PathDirection.CurrentToRoot, p.PathDirection, "PathDirection");
            p.PathSeparator = " - ";
            Style RootNodeStyle = new Style();

            p.RootNodeStyle.BackColor = Color.Red;
            p.ParentLevelsDisplayed   = 2;
            p.RenderCurrentNodeAsLink = true;
            p.SiteMapProvider         = "test";
            p.SkipLinkText            = "test";

            object           state = p.SaveState();
            PokerSiteMapPath copy  = new PokerSiteMapPath();

            copy.LoadState(state);
            Assert.IsFalse(copy.ShowToolTips, "ShowToolTips");
            Assert.AreEqual(Color.AliceBlue, copy.CurrentNodeStyle.ForeColor, "CurrentNodeStyle");
            Assert.AreEqual(Color.Aqua, p.NodeStyle.BackColor, "NodeStyle");
            Assert.AreEqual(" - ", p.PathSeparator, "PathSeparator");
            Assert.IsFalse(p.RootNodeStyle.IsEmpty, "RootNodeStyle#1");
            Assert.AreEqual(Color.Red, p.RootNodeStyle.BackColor, "RootNodeStyle#2");
            Assert.AreEqual(2, p.ParentLevelsDisplayed, "ParentLevelsDisplayed");
            Assert.IsTrue(p.RenderCurrentNodeAsLink, "RenderCurrentNodeAsLink");
            Assert.AreEqual("test", p.SiteMapProvider, "SiteMapProvider");
            Assert.AreEqual("test", p.SkipLinkText, "Skip Navigation Links");
        }
		public static void SiteMapRootNode (Page p)
		{
			PokerSiteMapPath smp = new PokerSiteMapPath ();
			Assert.AreEqual ("root", smp.Provider.RootNode.Title, "RootNode");
		}
		public static void InitializeItemTemplates (Page p)
		{
			PokerSiteMapPath smp = new PokerSiteMapPath ();
			SiteMapNodeItem I = new SiteMapNodeItem (1, SiteMapNodeItemType.Current);
			smp.CurrentNodeTemplate = new CompiledTemplateBuilder (templatebuilder);
			smp.CurrentNodeStyle.BackColor = Color.Red;
			smp.DoCreateControlHierarchy ();
			I.SiteMapNode = smp.Provider.CurrentNode;
			smp.InitilizeItems (I);

			Assert.AreEqual (1, I.Controls.Count, "InitializeItem#1");
			Assert.AreEqual (typeof (TextBox), I.Controls[0].GetType (), "InitializeItem#2");
			Assert.AreEqual (Color.Red, I.BackColor, "InitializeItem#3");
		}
		public static void InitializeItemPathSeparator (Page p)
		{
			PokerSiteMapPath smp = new PokerSiteMapPath ();
			SiteMapNodeItem I = new SiteMapNodeItem (0, SiteMapNodeItemType.PathSeparator);
			smp.PathSeparatorStyle.BorderColor = Color.Red;
			smp.InitilizeItems (I);
			Assert.AreEqual (1, I.Controls.Count, "InitializeItem#1");
			Assert.AreEqual (typeof (Literal), I.Controls[0].GetType (), "InitializeItem#2");
			Assert.AreEqual (Color.Red, I.BorderColor, "InitializeItem#3");
		}
		public static void InitializeItemParent (Page p)
		{
			PokerSiteMapPath smp = new PokerSiteMapPath ();
			SiteMapNodeItem I = new SiteMapNodeItem (0, SiteMapNodeItemType.Parent);
			smp.NodeStyle.BorderColor = Color.Red;
			smp.DoCreateControlHierarchy ();
			I.SiteMapNode = smp.Provider.RootNode;
			smp.InitilizeItems (I);

			Assert.AreEqual (1, I.Controls.Count, "InitializeItem#1");
			Assert.AreEqual (typeof (HyperLink), I.Controls[0].GetType (), "InitializeItem#2");
			Assert.AreEqual (Color.Red, ((HyperLink) I.Controls[0]).ControlStyle.BorderColor, "InitializeItem#4");
		}
		public static void InitializeItemCurrent (Page p)
		{
			PokerSiteMapPath smp = new PokerSiteMapPath ();
			SiteMapNodeItem I = new SiteMapNodeItem (1, SiteMapNodeItemType.Current);
			smp.CurrentNodeStyle.BackColor = Color.Red;
			smp.NodeStyle.BorderColor = Color.Red;
			smp.DoCreateControlHierarchy ();
			I.SiteMapNode = smp.Provider.CurrentNode;
			smp.InitilizeItems (I);
			
			Assert.AreEqual (1, I.Controls.Count, "InitializeItem#1");
			Assert.AreEqual (typeof (Literal), I.Controls[0].GetType (), "InitializeItem#2");
		        Assert.AreEqual (Color.Red, I.BackColor , "InitializeItem#3");
			Assert.AreEqual (Color.Red, I.BorderColor, "InitializeItem#4");

			I.Controls.Clear ();
			smp.RenderCurrentNodeAsLink = true;
			smp.InitilizeItems (I);
			
			Assert.AreEqual (1, I.Controls.Count, "InitializeItem#5");
			Assert.AreEqual (typeof (HyperLink), I.Controls[0].GetType (), "InitializeItem#6");
			Assert.AreEqual (Color.Red, I.BackColor, "InitializeItem#7");
			Assert.AreEqual (Color.Red, I.BorderColor, "InitializeItem#8");
		}
		public void SiteMapPath_ViewState ()
		{
			PokerSiteMapPath p = new PokerSiteMapPath ();
			p.ShowToolTips = false;
			Style currentNodeStyle = new Style ();
			p.CurrentNodeStyle.ForeColor = Color.AliceBlue;
			Style NodeStyle = new Style ();
			p.NodeStyle.BackColor = Color.Aqua;
			p.PathDirection = PathDirection.CurrentToRoot;
			Assert.AreEqual (PathDirection.CurrentToRoot, p.PathDirection, "PathDirection");
			p.PathSeparator = " - ";
			Style RootNodeStyle = new Style ();
			p.RootNodeStyle.BackColor = Color.Red;
			p.ParentLevelsDisplayed = 2;
			p.RenderCurrentNodeAsLink = true;
			p.SiteMapProvider = "test";
			p.SkipLinkText = "test";

			object state = p.SaveState ();
			PokerSiteMapPath copy = new PokerSiteMapPath ();
			copy.LoadState (state);
			Assert.IsFalse (copy.ShowToolTips, "ShowToolTips");
			Assert.AreEqual (Color.AliceBlue, copy.CurrentNodeStyle.ForeColor, "CurrentNodeStyle");
			Assert.AreEqual (Color.Aqua, p.NodeStyle.BackColor, "NodeStyle");
			Assert.AreEqual (" - ", p.PathSeparator, "PathSeparator");
			Assert.IsFalse (p.RootNodeStyle.IsEmpty, "RootNodeStyle#1");
			Assert.AreEqual (Color.Red, p.RootNodeStyle.BackColor, "RootNodeStyle#2");
			Assert.AreEqual (2, p.ParentLevelsDisplayed, "ParentLevelsDisplayed");
			Assert.IsTrue (p.RenderCurrentNodeAsLink, "RenderCurrentNodeAsLink");
			Assert.AreEqual ("test", p.SiteMapProvider, "SiteMapProvider");
			Assert.AreEqual ("test", p.SkipLinkText, "Skip Navigation Links");
		}
		public static void DoTestStylesRender (Page p)
		{
			PokerSiteMapPath smp = new PokerSiteMapPath ();
			smp.ControlStyle.BackColor = Color.Red;
			smp.CurrentNodeStyle.BackColor = Color.Pink;
			smp.NodeStyle.BorderColor = Color.Purple;
			smp.PathSeparatorStyle.BackColor = Color.RoyalBlue;
			smp.RootNodeStyle.BackColor = Color.Beige;
			LiteralControl lcb = new LiteralControl (HtmlDiff.BEGIN_TAG);
			LiteralControl lce = new LiteralControl (HtmlDiff.END_TAG);
			p.Form.Controls.Add (lcb);
			p.Form.Controls.Add (smp);
			p.Form.Controls.Add (lce);
		}
		public void SiteMapPath_NullProperties ()
		{
			PokerSiteMapPath p = new PokerSiteMapPath ();
			p.ShowToolTips = false;
			Assert.IsFalse (p.ShowToolTips, "ShowToolTips");
			Assert.AreEqual (1, p.StateBag.Count, "NullProperties#1");
			p.PathDirection = PathDirection.CurrentToRoot;
			Assert.AreEqual (PathDirection.CurrentToRoot, p.PathDirection, "PathDirection");
			Assert.AreEqual (2, p.StateBag.Count, "NullProperties#2");
			p.PathSeparator = " - ";
			Assert.AreEqual (3, p.StateBag.Count, "NullProperties#3");
			p.SiteMapProvider = "test";
			Assert.AreEqual (4, p.StateBag.Count, "NullProperties#4");
			p.SkipLinkText = "test";
			Assert.AreEqual (5, p.StateBag.Count, "NullProperties#5");
			p.SkipLinkText = null;
		}
		public void SiteMapPath_ChangeProperties ()
		{
			PokerSiteMapPath p = new PokerSiteMapPath ();
			p.ShowToolTips = false;
			Assert.IsFalse (p.ShowToolTips, "ShowToolTips");

			Style currentNodeStyle = new Style ();
			p.CurrentNodeStyle.ForeColor = Color.AliceBlue;
			Assert.AreEqual (Color.AliceBlue, p.CurrentNodeStyle.ForeColor, "CurrentNodeStyle");

			Style NodeStyle = new Style ();
			p.NodeStyle.BackColor = Color.Aqua;
			Assert.AreEqual (Color.Aqua, p.NodeStyle.BackColor, "NodeStyle");

			p.PathDirection = PathDirection.CurrentToRoot;
			Assert.AreEqual (PathDirection.CurrentToRoot, p.PathDirection, "PathDirection");

			p.PathSeparator = " - ";
			Assert.AreEqual (" - ", p.PathSeparator, "PathSeparator");

			Style RootNodeStyle = new Style ();
			p.RootNodeStyle.BackColor = Color.Red;
			Assert.IsFalse (p.RootNodeStyle.IsEmpty, "RootNodeStyle#1");
			Assert.AreEqual (Color.Red, p.RootNodeStyle.BackColor, "RootNodeStyle#2");

			p.ParentLevelsDisplayed = 2;
			Assert.AreEqual (2, p.ParentLevelsDisplayed, "ParentLevelsDisplayed");

			p.RenderCurrentNodeAsLink = true;
			Assert.IsTrue (p.RenderCurrentNodeAsLink, "RenderCurrentNodeAsLink");

			p.SiteMapProvider = "test";
			Assert.AreEqual ("test", p.SiteMapProvider, "SiteMapProvider");

			p.SkipLinkText = "test";
			Assert.AreEqual ("test", p.SkipLinkText, "Skip Navigation Links");

			//programmatically create template
			MyWebControl.Image myImage = new MyWebControl.Image ();
			myImage.ImageUrl = "myimage.jpg";
			ImageTemplate rootNodeImageTemplate = new ImageTemplate ();
			rootNodeImageTemplate.MyImage = myImage;
			// end create template image
			p.RootNodeTemplate = rootNodeImageTemplate;
			Assert.IsNotNull (p.RootNodeTemplate, "RootNodeTemplate");
			Assert.AreEqual (rootNodeImageTemplate, p.RootNodeTemplate, "RootNodeTemplate");

			p.NodeTemplate = rootNodeImageTemplate;
			Assert.IsNotNull (p.NodeTemplate, "NodeTemplate");
			Assert.AreEqual (rootNodeImageTemplate, p.NodeTemplate, "NodeTemplate");

			p.CurrentNodeTemplate = rootNodeImageTemplate;
			Assert.IsNotNull (p.CurrentNodeTemplate, "RootNodeTemplate");
			Assert.AreEqual (rootNodeImageTemplate, p.CurrentNodeTemplate, "RootNodeTemplate");
		}
		public void SiteMapPath_DefaultNotWorkingProperties()
		{
			PokerSiteMapPath p = new PokerSiteMapPath ();
			Assert.AreEqual (" > ", p.PathSeparator, "PathSeparator");
		}
Example #22
0
        public void SiteMapPath_DefaultNotWorkingProperties()
        {
            PokerSiteMapPath p = new PokerSiteMapPath();

            Assert.AreEqual(" > ", p.PathSeparator, "PathSeparator");
        }
		public static void SiteMapChildNode (Page p)
		{
			PokerSiteMapPath smp = new PokerSiteMapPath ();
			SiteMapNodeCollection myCol = smp.Provider.GetChildNodes (smp.Provider.RootNode);
			Assert.AreEqual (1, myCol.Count, "SiteMapChildNode#1");
		}
Example #24
0
        public static void SiteMapRootNode(Page p)
        {
            PokerSiteMapPath smp = new PokerSiteMapPath();

            Assert.AreEqual("root", smp.Provider.RootNode.Title, "RootNode");
        }
		public void Events (Page p)
		{
			PokerSiteMapPath smp = new PokerSiteMapPath ();
			ResetEvents ();
			smp.DataBinding += new EventHandler (DataBindingHandler);
			smp.ItemDataBound += new SiteMapNodeItemEventHandler (ItemDataBoundHandler);
			smp.ItemCreated += new SiteMapNodeItemEventHandler (ItemCreatedHandler);

			Assert.AreEqual (false, DataBinding, "BeforeDataBinding");
			smp.DoOnDataBinding (new EventArgs ());
			Assert.AreEqual (true, DataBinding, "AfterDataBinding");

			ResetEvents ();
			Assert.AreEqual (false, ItemDataBounding, "BeforeItemDataBound");
			SiteMapNodeItem i = new SiteMapNodeItem (0, SiteMapNodeItemType.Root);
			smp.DoOnItemDataBound (new SiteMapNodeItemEventArgs (i));
			Assert.AreEqual (true, ItemDataBounding, "AfterItemDataBound");

			ResetEvents ();
			SiteMapNodeItemEventArgs MyArgs = new SiteMapNodeItemEventArgs (new SiteMapNodeItem(0,SiteMapNodeItemType.Parent));
			Assert.AreEqual (false, ItemCreated, "BeforeItemCreated");
			smp.DoOnItemCteated (MyArgs);
			Assert.AreEqual (true, ItemCreated, "AfterItemCreated");
		}
		public void SiteMapPath_DefaultProperties ()
		{
			PokerSiteMapPath p = new PokerSiteMapPath ();
			Assert.IsTrue (p.CurrentNodeStyle.IsEmpty, "CurrentNodeStyle");
			Assert.IsNull (p.CurrentNodeTemplate, "CurrentNodeTemplate");
			Assert.IsTrue (p.NodeStyle.IsEmpty, "NodeStyle");
			Assert.IsNull (p.NodeTemplate, "NodeTemplate");
			Assert.AreEqual (-1, p.ParentLevelsDisplayed, "ParentLevelsDisplayed");
			Assert.AreEqual (PathDirection.RootToCurrent, p.PathDirection, "PathDirection");
			Assert.IsNull (p.PathSeparatorTemplate, "PathSeparatorTemplate");
			Assert.IsFalse (p.RenderCurrentNodeAsLink, "RenderCurrentNodeAsLink");
			Assert.IsTrue (p.RootNodeStyle.IsEmpty, "RootNodeStyle");
			Assert.IsNull (p.RootNodeTemplate, "RootNodeTemplate");
			Assert.IsTrue (p.ShowToolTips, "ShowToolTips");
			Assert.AreEqual ("", p.SiteMapProvider, "SiteMapProvider");
			Assert.AreEqual ("Skip Navigation Links", p.SkipLinkText, "Skip Navigation Links");
		}