public bool GetInitialized () {
return Initialized;
}
-#if NET_4_0
public string CallModifiedOuterTableStylePropertyName ()
{
return ModifiedOuterTableStylePropertyName ();
}
-#endif
}
class Template : ITemplate
{
string renderedPageHtml = new WebTest ("FormViewTest1.aspx").Run ();
string newHtmlValue = HtmlDiff.GetControlFromPageHtml (renderedPageHtml);
-#if NET_4_0
string origHtmlValue = "<table cellspacing=\"2\" cellpadding=\"3\" rules=\"all\" id=\"FormView1\" style=\"background-color:#DEBA84;border-color:#DEBA84;border-width:1px;border-style:None;\">\r\n\t<tr style=\"color:#8C4510;background-color:#FFF7E7;\">\r\n\t\t<td colspan=\"2\">\n <span id=\"FormView1_Label1\">1</span>\n </td>\r\n\t</tr><tr align=\"center\" style=\"color:#8C4510;\">\r\n\t\t<td colspan=\"2\"><table>\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('FormView1','Page$2')\" style=\"color:#8C4510;\">2</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$3')\" style=\"color:#8C4510;\">3</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$4')\" style=\"color:#8C4510;\">4</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$5')\" style=\"color:#8C4510;\">5</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$6')\" style=\"color:#8C4510;\">6</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";
-#else
- string origHtmlValue = "<table cellspacing=\"2\" cellpadding=\"3\" rules=\"all\" border=\"1\" id=\"FormView1\" style=\"background-color:#DEBA84;border-color:#DEBA84;border-width:1px;border-style:None;\">\r\n\t<tr style=\"color:#8C4510;background-color:#FFF7E7;\">\r\n\t\t<td colspan=\"2\">\n <span id=\"FormView1_Label1\">1</span>\n </td>\r\n\t</tr><tr align=\"center\" style=\"color:#8C4510;\">\r\n\t\t<td colspan=\"2\"><table border=\"0\">\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('FormView1','Page$2')\" style=\"color:#8C4510;\">2</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$3')\" style=\"color:#8C4510;\">3</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$4')\" style=\"color:#8C4510;\">4</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$5')\" style=\"color:#8C4510;\">5</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$6')\" style=\"color:#8C4510;\">6</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";
-#endif
HtmlDiff.AssertAreEqual (origHtmlValue, newHtmlValue, "RenderSimpleTemplate");
}
{
string renderedPageHtml = new WebTest ("FormViewTest1_2.aspx").Run ();
string newHtmlValue = HtmlDiff.GetControlFromPageHtml (renderedPageHtml);
-#if NET_4_0
string origHtmlValue = "<table cellspacing=\"0\" cellpadding=\"4\" id=\"FormView2\" style=\"color:#333333;border-collapse:collapse;\">\r\n\t<tr style=\"color:#333333;background-color:#F7F6F3;\">\r\n\t\t<td colspan=\"2\">\n <span id=\"FormView2_Label2\">1</span>\n </td>\r\n\t</tr><tr style=\"color:White;background-color:#5D7B9D;font-weight:bold;\">\r\n\t\t<td colspan=\"2\">\n <span id=\"FormView2_Label3\">Footer Template Test</span>\n </td>\r\n\t</tr><tr align=\"center\" style=\"color:White;background-color:#284775;\">\r\n\t\t<td colspan=\"2\">\n <input type=\"submit\" name=\"FormView2$ctl01$Button1\" value=\"Prev Item\" id=\"FormView2_ctl01_Button1\" />\n <input type=\"submit\" name=\"FormView2$ctl01$Button2\" value=\"Next Item\" id=\"FormView2_ctl01_Button2\" />\n <input type=\"submit\" name=\"FormView2$ctl01$Button3\" value=\"First Item\" id=\"FormView2_ctl01_Button3\" />\n <input type=\"submit\" name=\"FormView2$ctl01$Button4\" value=\"Last Item\" id=\"FormView2_ctl01_Button4\" />\n </td>\r\n\t</tr>\r\n</table>";
-#else
- string origHtmlValue = "<table cellspacing=\"0\" cellpadding=\"4\" border=\"0\" id=\"FormView2\" style=\"color:#333333;border-collapse:collapse;\">\r\n\t<tr style=\"color:#333333;background-color:#F7F6F3;\">\r\n\t\t<td colspan=\"2\">\n <span id=\"FormView2_Label2\">1</span>\n </td>\r\n\t</tr><tr style=\"color:White;background-color:#5D7B9D;font-weight:bold;\">\r\n\t\t<td colspan=\"2\">\n <span id=\"FormView2_Label3\">Footer Template Test</span>\n </td>\r\n\t</tr><tr align=\"center\" style=\"color:White;background-color:#284775;\">\r\n\t\t<td colspan=\"2\">\n <input type=\"submit\" name=\"FormView2$ctl01$Button1\" value=\"Prev Item\" id=\"FormView2_ctl01_Button1\" />\n <input type=\"submit\" name=\"FormView2$ctl01$Button2\" value=\"Next Item\" id=\"FormView2_ctl01_Button2\" />\n <input type=\"submit\" name=\"FormView2$ctl01$Button3\" value=\"First Item\" id=\"FormView2_ctl01_Button3\" />\n <input type=\"submit\" name=\"FormView2$ctl01$Button4\" value=\"Last Item\" id=\"FormView2_ctl01_Button4\" />\n </td>\r\n\t</tr>\r\n</table>";
-#endif
HtmlDiff.AssertAreEqual (origHtmlValue, newHtmlValue, "FormView_RenderFooterAndPager");
}
{
string renderedPageHtml = new WebTest ("FormViewTest1_4.aspx").Run ();
string newHtmlValue = HtmlDiff.GetControlFromPageHtml (renderedPageHtml);
-#if NET_4_0
string origHtmlValue = "<table cellspacing=\"10\" cellpadding=\"3\" align=\"Right\" rules=\"all\" id=\"FormView4\" style=\"background-color:White;border-color:#CCCCCC;border-width:1px;border-style:None;\">\r\n\t<tr align=\"left\" style=\"color:White;background-color:#006699;font-weight:bold;\">\r\n\t\t<td colspan=\"2\">Using Header Text property</td>\r\n\t</tr><tr align=\"center\" style=\"color:#000066;background-color:Maroon;\">\r\n\t\t<td colspan=\"2\">Using Footer Text property</td>\r\n\t</tr><tr align=\"left\" style=\"color:#000066;background-color:LightGrey;\">\r\n\t\t<td colspan=\"2\">\n <a id=\"FormView4_ctl01_LinkButton1\" href=\"javascript:__doPostBack('FormView4$ctl01$LinkButton1','')\">Next</a>\n <a id=\"FormView4_ctl01_LinkButton2\" href=\"javascript:__doPostBack('FormView4$ctl01$LinkButton2','')\">Prev</a>\n <span id=\"FormView4_ctl01_Label7\">Page Index: 0</span>\n </td>\r\n\t</tr>\r\n</table>";
-#else
- string origHtmlValue = "<table cellspacing=\"10\" cellpadding=\"3\" align=\"Right\" rules=\"all\" border=\"1\" id=\"FormView4\" style=\"background-color:White;border-color:#CCCCCC;border-width:1px;border-style:None;\">\r\n\t<tr align=\"left\" style=\"color:White;background-color:#006699;font-weight:bold;\">\r\n\t\t<td colspan=\"2\">Using Header Text property</td>\r\n\t</tr><tr align=\"center\" style=\"color:#000066;background-color:Maroon;\">\r\n\t\t<td colspan=\"2\">Using Footer Text property</td>\r\n\t</tr><tr align=\"left\" style=\"color:#000066;background-color:LightGrey;\">\r\n\t\t<td colspan=\"2\">\n <a id=\"FormView4_ctl01_LinkButton1\" href=\"javascript:__doPostBack('FormView4$ctl01$LinkButton1','')\">Next</a>\n <a id=\"FormView4_ctl01_LinkButton2\" href=\"javascript:__doPostBack('FormView4$ctl01$LinkButton2','')\">Prev</a>\n <span id=\"FormView4_ctl01_Label7\">Page Index: 0</span>\n </td>\r\n\t</tr>\r\n</table>";
-#endif
HtmlDiff.AssertAreEqual (origHtmlValue, newHtmlValue, "RenderingDefaultPaging");
}
{
string RenderedPageHtml = new WebTest ("FormViewTest1_3.aspx").Run ();
string newHtmlValue = HtmlDiff.GetControlFromPageHtml (RenderedPageHtml);
-#if NET_4_0
string origHtmlValue = "<table cellspacing=\"0\" cellpadding=\"2\" id=\"FormView3\" style=\"color:Black;background-color:LightGoldenrodYellow;border-color:Tan;border-width:1px;border-style:solid;border-collapse:collapse;\">\r\n\t<tr align=\"center\" valign=\"top\" style=\"color:#C00000;background-color:Tan;font-weight:bold;\">\r\n\t\t<td colspan=\"2\">\n <span id=\"FormView3_Label5\">Header Template Test</span>\n </td>\r\n\t</tr><tr>\r\n\t\t<td colspan=\"2\">\n <span id=\"FormView3_Label4\">1</span>\n </td>\r\n\t</tr><tr align=\"right\" style=\"color:#FFC0FF;background-color:Tan;\">\r\n\t\t<td colspan=\"2\">\n <span id=\"FormView3_Label6\">FormView Footer</span>\n </td>\r\n\t</tr><tr align=\"center\" style=\"color:DarkSlateBlue;background-color:PaleGoldenrod;\">\r\n\t\t<td colspan=\"2\"><table>\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('FormView3','Page$2')\" style=\"color:DarkSlateBlue;\">2</a></td><td><a href=\"javascript:__doPostBack('FormView3','Page$3')\" style=\"color:DarkSlateBlue;\">3</a></td><td><a href=\"javascript:__doPostBack('FormView3','Page$4')\" style=\"color:DarkSlateBlue;\">4</a></td><td><a href=\"javascript:__doPostBack('FormView3','Page$5')\" style=\"color:DarkSlateBlue;\">5</a></td><td><a href=\"javascript:__doPostBack('FormView3','Page$6')\" style=\"color:DarkSlateBlue;\">6</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";
-#else
- string origHtmlValue = "<table cellspacing=\"0\" cellpadding=\"2\" border=\"0\" id=\"FormView3\" style=\"color:Black;background-color:LightGoldenrodYellow;border-color:Tan;border-width:1px;border-style:solid;border-collapse:collapse;\">\r\n\t<tr align=\"center\" valign=\"top\" style=\"color:#C00000;background-color:Tan;font-weight:bold;\">\r\n\t\t<td colspan=\"2\">\n <span id=\"FormView3_Label5\">Header Template Test</span>\n </td>\r\n\t</tr><tr>\r\n\t\t<td colspan=\"2\">\n <span id=\"FormView3_Label4\">1</span>\n </td>\r\n\t</tr><tr align=\"right\" style=\"color:#FFC0FF;background-color:Tan;\">\r\n\t\t<td colspan=\"2\">\n <span id=\"FormView3_Label6\">FormView Footer</span>\n </td>\r\n\t</tr><tr align=\"center\" style=\"color:DarkSlateBlue;background-color:PaleGoldenrod;\">\r\n\t\t<td colspan=\"2\"><table border=\"0\">\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('FormView3','Page$2')\" style=\"color:DarkSlateBlue;\">2</a></td><td><a href=\"javascript:__doPostBack('FormView3','Page$3')\" style=\"color:DarkSlateBlue;\">3</a></td><td><a href=\"javascript:__doPostBack('FormView3','Page$4')\" style=\"color:DarkSlateBlue;\">4</a></td><td><a href=\"javascript:__doPostBack('FormView3','Page$5')\" style=\"color:DarkSlateBlue;\">5</a></td><td><a href=\"javascript:__doPostBack('FormView3','Page$6')\" style=\"color:DarkSlateBlue;\">6</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";
-#endif
HtmlDiff.AssertAreEqual (origHtmlValue, newHtmlValue, "RenderingDefaultPaging");
}
WebTest t = new WebTest ("FormViewInsertEditDelete.aspx");
string pageHTML = t.Run ();
string newHtml = HtmlDiff.GetControlFromPageHtml (pageHTML);
-#if NET_4_0
string origHtml = "<table cellspacing=\"0\" id=\"FormView1\" style=\"border-collapse:collapse;\">\r\n\t<tr>\r\n\t\t<td colspan=\"2\">\n <span id=\"FormView1_ID\">1001</span> \n <span id=\"FormView1_LName\">Chand</span>\n <span id=\"FormView1_FName\">Mahesh</span> \n <a id=\"FormView1_EditButton\" href=\"javascript:__doPostBack('FormView1$EditButton','')\">Edit</a>\n <a id=\"FormView1_NewButton\" href=\"javascript:__doPostBack('FormView1$NewButton','')\">New</a>\n <a id=\"FormView1_DeleteButton\" href=\"javascript:__doPostBack('FormView1$DeleteButton','')\">Delete</a>\n </td>\r\n\t</tr><tr>\r\n\t\t<td colspan=\"2\"><table>\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('FormView1','Page$2')\">2</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$3')\">3</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";
-#else
- string origHtml = "<table cellspacing=\"0\" border=\"0\" id=\"FormView1\" style=\"border-collapse:collapse;\">\r\n\t<tr>\r\n\t\t<td colspan=\"2\">\n <span id=\"FormView1_ID\">1001</span> \n <span id=\"FormView1_LName\">Chand</span>\n <span id=\"FormView1_FName\">Mahesh</span> \n <a id=\"FormView1_EditButton\" href=\"javascript:__doPostBack('FormView1$EditButton','')\">Edit</a>\n <a id=\"FormView1_NewButton\" href=\"javascript:__doPostBack('FormView1$NewButton','')\">New</a>\n <a id=\"FormView1_DeleteButton\" href=\"javascript:__doPostBack('FormView1$DeleteButton','')\">Delete</a>\n </td>\r\n\t</tr><tr>\r\n\t\t<td colspan=\"2\"><table border=\"0\">\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('FormView1','Page$2')\">2</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$3')\">3</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";
-#endif
HtmlDiff.AssertAreEqual (origHtml, newHtml, "BeforeEditPostback");
//Edit button postback (change to edit mode - buttons "Update" and "Cancel" should appear.
t.Request = fr;
pageHTML = t.Run ();
newHtml = HtmlDiff.GetControlFromPageHtml (pageHTML);
-#if NET_4_0
origHtml = "<table cellspacing=\"0\" id=\"FormView1\" style=\"border-collapse:collapse;\">\r\n\t<tr>\r\n\t\t<td colspan=\"2\">\n Enter First Name:<input name=\"FormView1$FNameEdit\" type=\"text\" value=\"Mahesh\" id=\"FormView1_FNameEdit\" /><br />\n Enter Last Name:<input name=\"FormView1$LNameEdit\" type=\"text\" value=\"Chand\" id=\"FormView1_LNameEdit\" /><br />\n <a id=\"FormView1_UpdateButton\" href=\"javascript:__doPostBack('FormView1$UpdateButton','')\">Update</a>\n <a id=\"FormView1_CancelUpdateButton\" href=\"javascript:__doPostBack('FormView1$CancelUpdateButton','')\">Cancel</a>\n </td>\r\n\t</tr><tr>\r\n\t\t<td colspan=\"2\"><table>\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('FormView1','Page$2')\">2</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$3')\">3</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";
-#else
- origHtml = "<table cellspacing=\"0\" border=\"0\" id=\"FormView1\" style=\"border-collapse:collapse;\">\r\n\t<tr>\r\n\t\t<td colspan=\"2\">\n Enter First Name:<input name=\"FormView1$FNameEdit\" type=\"text\" value=\"Mahesh\" id=\"FormView1_FNameEdit\" /><br />\n Enter Last Name:<input name=\"FormView1$LNameEdit\" type=\"text\" value=\"Chand\" id=\"FormView1_LNameEdit\" /><br />\n <a id=\"FormView1_UpdateButton\" href=\"javascript:__doPostBack('FormView1$UpdateButton','')\">Update</a>\n <a id=\"FormView1_CancelUpdateButton\" href=\"javascript:__doPostBack('FormView1$CancelUpdateButton','')\">Cancel</a>\n </td>\r\n\t</tr><tr>\r\n\t\t<td colspan=\"2\"><table border=\"0\">\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('FormView1','Page$2')\">2</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$3')\">3</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";
-#endif
HtmlDiff.AssertAreEqual (origHtml, newHtml, "AfterEditPostback");
//Update record postback
t.Request = fr;
pageHTML = t.Run ();
newHtml = HtmlDiff.GetControlFromPageHtml (pageHTML);
-#if NET_4_0
origHtml = "<table cellspacing=\"0\" id=\"FormView1\" style=\"border-collapse:collapse;\">\r\n\t<tr>\r\n\t\t<td colspan=\"2\">\n <span id=\"FormView1_ID\">1001</span> \n <span id=\"FormView1_LName\">Test</span>\n <span id=\"FormView1_FName\">Merav</span> \n <a id=\"FormView1_EditButton\" href=\"javascript:__doPostBack('FormView1$EditButton','')\">Edit</a>\n <a id=\"FormView1_NewButton\" href=\"javascript:__doPostBack('FormView1$NewButton','')\">New</a>\n <a id=\"FormView1_DeleteButton\" href=\"javascript:__doPostBack('FormView1$DeleteButton','')\">Delete</a>\n </td>\r\n\t</tr><tr>\r\n\t\t<td colspan=\"2\"><table>\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('FormView1','Page$2')\">2</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$3')\">3</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";
-#else
- origHtml = "<table cellspacing=\"0\" border=\"0\" id=\"FormView1\" style=\"border-collapse:collapse;\">\r\n\t<tr>\r\n\t\t<td colspan=\"2\">\n <span id=\"FormView1_ID\">1001</span> \n <span id=\"FormView1_LName\">Test</span>\n <span id=\"FormView1_FName\">Merav</span> \n <a id=\"FormView1_EditButton\" href=\"javascript:__doPostBack('FormView1$EditButton','')\">Edit</a>\n <a id=\"FormView1_NewButton\" href=\"javascript:__doPostBack('FormView1$NewButton','')\">New</a>\n <a id=\"FormView1_DeleteButton\" href=\"javascript:__doPostBack('FormView1$DeleteButton','')\">Delete</a>\n </td>\r\n\t</tr><tr>\r\n\t\t<td colspan=\"2\"><table border=\"0\">\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('FormView1','Page$2')\">2</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$3')\">3</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";
-#endif
HtmlDiff.AssertAreEqual (origHtml, newHtml, "AfterUpdatePostback");
//Postback to return to Edit mode
t.Request = fr;
pageHTML = t.Run ();
newHtml = HtmlDiff.GetControlFromPageHtml (pageHTML);
-#if NET_4_0
origHtml = "<table cellspacing=\"0\" id=\"FormView1\" style=\"border-collapse:collapse;\">\r\n\t<tr>\r\n\t\t<td colspan=\"2\">\n <span id=\"FormView1_ID\">1001</span> \n <span id=\"FormView1_LName\">Test</span>\n <span id=\"FormView1_FName\">Merav</span> \n <a id=\"FormView1_EditButton\" href=\"javascript:__doPostBack('FormView1$EditButton','')\">Edit</a>\n <a id=\"FormView1_NewButton\" href=\"javascript:__doPostBack('FormView1$NewButton','')\">New</a>\n <a id=\"FormView1_DeleteButton\" href=\"javascript:__doPostBack('FormView1$DeleteButton','')\">Delete</a>\n </td>\r\n\t</tr><tr>\r\n\t\t<td colspan=\"2\"><table>\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('FormView1','Page$2')\">2</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$3')\">3</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";
-#else
- origHtml = "<table cellspacing=\"0\" border=\"0\" id=\"FormView1\" style=\"border-collapse:collapse;\">\r\n\t<tr>\r\n\t\t<td colspan=\"2\">\n <span id=\"FormView1_ID\">1001</span> \n <span id=\"FormView1_LName\">Test</span>\n <span id=\"FormView1_FName\">Merav</span> \n <a id=\"FormView1_EditButton\" href=\"javascript:__doPostBack('FormView1$EditButton','')\">Edit</a>\n <a id=\"FormView1_NewButton\" href=\"javascript:__doPostBack('FormView1$NewButton','')\">New</a>\n <a id=\"FormView1_DeleteButton\" href=\"javascript:__doPostBack('FormView1$DeleteButton','')\">Delete</a>\n </td>\r\n\t</tr><tr>\r\n\t\t<td colspan=\"2\"><table border=\"0\">\r\n\t\t\t<tr>\r\n\t\t\t\t<td><span>1</span></td><td><a href=\"javascript:__doPostBack('FormView1','Page$2')\">2</a></td><td><a href=\"javascript:__doPostBack('FormView1','Page$3')\">3</a></td>\r\n\t\t\t</tr>\r\n\t\t</table></td>\r\n\t</tr>\r\n</table>";
-#endif
HtmlDiff.AssertAreEqual (origHtml, newHtml, "CancelEditedRecordPostback");
}
[Test (Description="Bug #578863")]
public void FormView_PagerSettings_Visibility ()
{
-#if NET_4_0
string origHtml = "<table cellspacing=\"2\" cellpadding=\"3\" rules=\"all\" id=\"FormView1\" style=\"background-color:#DEBA84;border-color:#DEBA84;border-width:1px;border-style:None;\">\r\n\t<tr style=\"color:#8C4510;background-color:#FFF7E7;\">\r\n\t\t<td colspan=\"2\">\n <span id=\"FormView1_Label1\">1</span>\n\t</td>\r\n\t</tr>\r\n</table>";
-#else
- string origHtml = "<table cellspacing=\"2\" cellpadding=\"3\" rules=\"all\" border=\"1\" id=\"FormView1\" style=\"background-color:#DEBA84;border-color:#DEBA84;border-width:1px;border-style:None;\">\r\n\t<tr style=\"color:#8C4510;background-color:#FFF7E7;\">\r\n\t\t<td colspan=\"2\">\n <span id=\"FormView1_Label1\">1</span>\n\t</td>\r\n\t</tr>\r\n</table>";
-#endif
WebTest t = new WebTest ("FormViewPagerVisibility.aspx");
string pageHtml = t.Run ();
string renderedHtml = HtmlDiff.GetControlFromPageHtml (pageHtml);
t.Request = fr;
pageHTML = t.Run ();
string newHtml = HtmlDiff.GetControlFromPageHtml (pageHTML);
-#if NET_4_0
string origHtml = "<table cellspacing=\"0\" id=\"FormView1\" style=\"border-collapse:collapse;\">\r\n\t<tr>\r\n\t\t<td colspan=\"2\">\n Insert ID:\n <input name=\"FormView1$IDInsert\" type=\"text\" id=\"FormView1_IDInsert\" /><br />\n Insert First Name:\n <input name=\"FormView1$FNameInsert\" type=\"text\" id=\"FormView1_FNameInsert\" />\n <br />\n Insert Last Name: \n <input name=\"FormView1$LNameInsert\" type=\"text\" id=\"FormView1_LNameInsert\" />\n <a id=\"FormView1_InsertButton\" href=\"javascript:__doPostBack('FormView1$InsertButton','')\">Insert</a>\n <a id=\"FormView1_CancelInsertButton\" href=\"javascript:__doPostBack('FormView1$CancelInsertButton','')\">Cancel</a>\n </td>\r\n\t</tr>\r\n</table>";
-#else
- string origHtml = "<table cellspacing=\"0\" border=\"0\" id=\"FormView1\" style=\"border-collapse:collapse;\">\r\n\t<tr>\r\n\t\t<td colspan=\"2\">\n Insert ID:\n <input name=\"FormView1$IDInsert\" type=\"text\" id=\"FormView1_IDInsert\" /><br />\n Insert First Name:\n <input name=\"FormView1$FNameInsert\" type=\"text\" id=\"FormView1_FNameInsert\" />\n <br />\n Insert Last Name: \n <input name=\"FormView1$LNameInsert\" type=\"text\" id=\"FormView1_LNameInsert\" />\n <a id=\"FormView1_InsertButton\" href=\"javascript:__doPostBack('FormView1$InsertButton','')\">Insert</a>\n <a id=\"FormView1_CancelInsertButton\" href=\"javascript:__doPostBack('FormView1$CancelInsertButton','')\">Cancel</a>\n </td>\r\n\t</tr>\r\n</table>";
-#endif
HtmlDiff.AssertAreEqual (origHtml, newHtml, "InsertPostback");
//Insert new record
}
public static void BuildTemplateMethod (Control c) { }
-#if NET_4_0
[Test]
public void ModifiedOuterTableStylePropertyName ()
{
Assert.IsNotNull (props, "#B1-1");
Assert.AreEqual ("BackImageUrl", props, "#B1-2");
}
-#endif
}
public class TestMyData