I am new to the Nunit,nunitasp i am gettin an error as
"System.InvalidOperationException:the specified node cannot be inserted as the valid child of this node, because the specified node is the wrong type"
i have used nunit.framework,nunitasp as references ,but when i am using txt1.tex="asdf", then i am getting can u plz send the reply as soon as possible
Expand|Select|Wrap|Line Numbers
- ******************
- using System;
- using System.Web;
- using MyMathProject;
- using MyWebApp;
- using NUnit.Extensions;
- using NUnit.Extensions.Asp;
- using NUnit.Extensions.Asp.AspTester ;
- using NUnit.Extensions.Asp.HtmlTester;
- namespace MyMathProjectTest
- {
- /// <summary>
- /// Summary description for Class1.
- /// </summary>
- ///
- using NUnit.Framework;
- [TestFixture]
- public class Class1: NUnit.Extensions.Asp.WebFormTestCase
- {
- public Class1()
- {
- //
- // TODO: Add constructor logic here
- //
- }
- [Test] public void Subtract()
- {
- //Assert.AreEqual(1.1, MyMathProject.MySimpleMath.Subtract(2.2, 1.1), "Subtraction failed");
- }
- [Test] public void formLayout()
- {
- NUnit.Extensions.Asp.AspTester.TextBoxTester txt1 = new TextBoxTester("TextBox1", CurrentWebForm);
- TextBoxTester txt2 = new TextBoxTester("TextBox2", CurrentWebForm);
- ButtonTester but1 = new ButtonTester("Button1", CurrentWebForm);
- Browser.GetPage("http://localhost/MyWebApp/Custtest.aspx");
- txt1.Text="asdf";
- }
- }
- }