diff options
author | thomasvl <thomasvl@7dc7ac4e-7543-0410-b95c-c1676fc8e2a3> | 2008-06-13 19:21:50 +0000 |
---|---|---|
committer | thomasvl <thomasvl@7dc7ac4e-7543-0410-b95c-c1676fc8e2a3> | 2008-06-13 19:21:50 +0000 |
commit | c53ec5520e39096e0804ce8d89a21378c0904481 (patch) | |
tree | d36a0055b59b1376d86c4ba4a01f9c479c2101a7 /UnitTesting/GTMAppKit+UnitTesting.h | |
parent | 80d493da05c8d461d74bfaa919ffc487be03ffe6 (diff) |
Landing a log of AppleScript/AppleEvent support code.
Landing GTMHTTPServer as a simple server but mainly for use in unittesting.
_GTMCompileAssert for doing compile time assertions to GTMDefines.h
Lots of improvments for UnitTesting, Dave's gonna put up a wiki page shortly with the full details of what can be done.
Diffstat (limited to 'UnitTesting/GTMAppKit+UnitTesting.h')
-rw-r--r-- | UnitTesting/GTMAppKit+UnitTesting.h | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/UnitTesting/GTMAppKit+UnitTesting.h b/UnitTesting/GTMAppKit+UnitTesting.h index 5db9ebb..016da7e 100644 --- a/UnitTesting/GTMAppKit+UnitTesting.h +++ b/UnitTesting/GTMAppKit+UnitTesting.h @@ -52,7 +52,7 @@ @protocol GTMUnitTestViewDrawer; // Fails when the |a1|'s drawing in an area |a2| does not equal the image file named |a3|. -// See the description of the GTMAssertViewRepEqualToFile macro +// See the description of the -gtm_pathForImageNamed method // to understand how |a3| is found and written out. // See the description of the GTMUnitTestView for a better idea // how the view works. @@ -70,15 +70,14 @@ // ...: A variable number of arguments to the format string. Can be absent. // - -#define GTMAssertDrawingEqualToFile(a1, a2, a3, a4, description, ...) \ +#define GTMAssertDrawingEqualToImageNamed(a1, a2, a3, a4, description, ...) \ do { \ - id<GTMUnitTestViewDrawer> a1Object = (a1); \ + id<GTMUnitTestViewDrawer> a1Drawer = (a1); \ NSSize a2Size = (a2); \ NSString* a3String = (a3); \ void *a4ContextInfo = (a4); \ NSRect frame = NSMakeRect(0, 0, a2Size.width, a2Size.height); \ - GTMUnitTestView *view = [[[GTMUnitTestView alloc] initWithFrame:frame drawer:a1Object contextInfo:a4ContextInfo] autorelease]; \ + GTMUnitTestView *view = [[[GTMUnitTestView alloc] initWithFrame:frame drawer:a1Drawer contextInfo:a4ContextInfo] autorelease]; \ GTMAssertObjectImageEqualToImageNamed(view, a3String, STComposeString(description, ##__VA_ARGS__)); \ } while(0) |