Cedric is an Avid Reader. No contributions for 2024.
Without a doubt, there will be something to
share on the Community in 2025!
User bio
404 bio not found
Member since Jan 10, 2023
Replies:

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. 
 

Certifications & Credly badges:
Cedric has no Certifications & Credly badges yet.
Global Masters badges:
Followers:
Cedric has no followers yet.
Following:
Cedric has not followed anybody yet.