Hi!
I'm creating my first test projekt using NUnitASP, I have a simple code
snippet that I can=B4t get to work properly. I'm using VB.NET and the
examples I found on the internet is in C#.=20
This is my code:
------------------------------------------------------------------------=
----
----------------------------------------
Imports System
Imports System.Web
Imports NUnit.Framework
Imports NUnit.Extensions.Asp
Imports NUnit.Extensions.Asp.AspTester
Imports UserInterfaceProcess
<TestFixture()> _
Public Class NUUserInterface
Inherits WebFormTestCase
<Test()> _
Public Sub Check_btnSearch()
' Declare the button:
Dim abtnSearch As New ButtonTester("btnSearch", currentwebform)
' Download the main page:
=
browser.GetPage("http://localhost/PartMasterWeb_1/searchPart.aspx")
Assert("Wrong page!", currentwebform.AspId =3D "mainpage")
' Make sure that logout button exists...
AssertVisibility(abtnSearch, True)
' click on it
abtnSearch.Click()
' check we are in the correct page
Assert("Wrong page!", currentwebform.AspId =3D "frmLogin")
End Sub
'txtSearchPart -> textfield
End Class
------------------------------------------------------------------------=
----
----------------------------------------
I recieve an error when running the code (no problems to build it), the
error occours on browser.GetPage(......
This is the error message recieved indicates that the objectreference =
is not
an instance of an object.=20
Thanks in advance for any help!
Malin
|