This is the class which I want to test.
Class GSK.MyTestUnit Extends %RegisteredObject {
ClassMethod Add(num1 As %Integer, num2 As %Integer) { s res=num1+num2 q res } }
This is my testing class.
Class GSK.TestingClass Extends %UnitTest.TestCase {
Method test() { Do $$$AssertEquals(##class(GSK.MyTestUnit).Add(3,8),41, "Test Add(2,2)=4 passed ") do $$$AssertNotEquals(##class(GSK.MyTestUnit).Add(3,8),11,"pass/fail") }
}
The test cases are passed even though they should fail.
s ^UnitTestRoot="C:\TestSuite1" d ##class(%UnitTest.Manager).RunTest("Test2")






