So I instantiated the class but it didn't work either
terminal :
unitTests.testSqlAgateInscription begins ...
TestMyMethod() begins ...
LogStateStatus:0:TestMyMethod:ERREUR #5002: Erreur Cache: <INVALID OREF>zTestMyMethod+4^unitTests.testSqlInscription.1 <<==== **FAILED**
unitTests:unitTests.testSqlInscription:TestMyMethod:
TestMyMethod failed
unitTests.testSqlInscription failed
unitTests failed
The code looks like that :
Class unitTests.testSqlInscription Extends %UnitTest.TestCase
{
Method TestMyMethod()
{
set myObject = ##class(Package.BO.sqlInscription).%New()
set myRequest = ##class(Package.Msg.getSomeDataFromDataBaseRequest).%New()
set myRequest.somePropertyaboutEmail = "test@mail.com"
do $$$AssertEquals(myObject.getSomeDataFromDataBase(myRequest),1953642, "Test MyMethod()=1953642")
}
}
I'm really out of ideas here to set up a basic unit test. Any hint is much welcome.
Please and thank you.
- Log in to post comments