Work at SourceForge, help us to make it a better place! We have an immediate need for a Support Technician in our San Francisco or Denver office.

Close

#437 Weird error in testUnit

3.2.0
closed
Rick McGuire
Classes (182)
5
2012-08-14
2007-10-09
TheDavidFactor
No

I'm working on developing negative test cases in the array testunit and ran
in to this problem:

My test code:
a = .array~new()
a~put()

Raises:
4 - a~put()
Error 93 running C:\Dev\temp\test.rex line 4: Incorrect call to method
Error 93.903: Missing argument in method; argument 1 is required

However when I put it in the test unit like this:
::method "test_put_syntax1"

a=.array~new()
self~expectSyntax("93.903")
a~put()

I get this:
[20071009 12:51:57.186000]: [error] testCase: [TEST_PUT_SYNTAX1] (an
ooRexx.Base.Class.Array.TestUnit@C:\Dev\ooRexx\test\tests\oorexxunit\ooRexx\ baseclass\ooRexx.Base.Class.Array.testUnit) ---> condition [SYNTAX 93.905]
raised unexpectedly. Method argument -2 must be a whole number; found "an
Array"

Simplified testUnit is attached

Discussion

  • Rick McGuire
    Rick McGuire
    2007-10-09

    Logged In: YES
    user_id=1125291
    Originator: NO

    Committed revision 909.

     


Anonymous


Cancel   Add attachments