@@ -18,10 +18,11 @@ #import "OFString.h" #import "OFNumber.h" #import "OFAutoreleasePool.h" +#import "OFInvalidArgumentException.h" #import "OFMemoryNotPartOfObjectException.h" #import "OFOutOfMemoryException.h" #import "OFUndefinedKeyException.h" #import "TestsAppDelegate.h" @@ -252,9 +253,13 @@ [m unsignedIntValue] == 80 && [m unsignedLongValue] == 90 && [m unsignedLongLongValue] == 100 && [m floatValue] == 110 && [m doubleValue] == 120) + + EXPECT_EXCEPTION(@"Catch -[setValue:forKey:] with nil key for scalar", + OFInvalidArgumentException, [m setValue: nil + forKey: @"intValue"]) [pool drain]; } @end