Author: davide Date: Wed Mar 14 17:07:05 2018 New Revision: 327592 URL: http://llvm.org/viewvc/llvm-project?rev=327592&view=rev Log: [Dictionary] Rewrite the test added in r327587 as an inline test.
Until we have a better story for putting commands and check lines in the same file (they're currently ignored), it seems that inline tests are actually more concise and easier to understand. Too bad we have still some python boilerplate, but that's not really substantial so we can live with it. Thanks to Fred for pointing out and Jim for explaining me how to use the inline test format. <rdar://problem/34806516> Added: lldb/trunk/packages/Python/lldbsuite/test/lang/objc/objc-foundation-dictionary-empty/ lldb/trunk/packages/Python/lldbsuite/test/lang/objc/objc-foundation-dictionary-empty/TestNSDictionary0.py lldb/trunk/packages/Python/lldbsuite/test/lang/objc/objc-foundation-dictionary-empty/main.m Removed: lldb/trunk/lit/DataFormatters/ Added: lldb/trunk/packages/Python/lldbsuite/test/lang/objc/objc-foundation-dictionary-empty/TestNSDictionary0.py URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/lang/objc/objc-foundation-dictionary-empty/TestNSDictionary0.py?rev=327592&view=auto ============================================================================== --- lldb/trunk/packages/Python/lldbsuite/test/lang/objc/objc-foundation-dictionary-empty/TestNSDictionary0.py (added) +++ lldb/trunk/packages/Python/lldbsuite/test/lang/objc/objc-foundation-dictionary-empty/TestNSDictionary0.py Wed Mar 14 17:07:05 2018 @@ -0,0 +1,6 @@ +from lldbsuite.test import lldbinline +from lldbsuite.test import decorators + +lldbinline.MakeInlineTest( + __file__, globals(), [ + decorators.skipIfFreeBSD, decorators.skipIfLinux, decorators.skipIfWindows]) Added: lldb/trunk/packages/Python/lldbsuite/test/lang/objc/objc-foundation-dictionary-empty/main.m URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/lang/objc/objc-foundation-dictionary-empty/main.m?rev=327592&view=auto ============================================================================== --- lldb/trunk/packages/Python/lldbsuite/test/lang/objc/objc-foundation-dictionary-empty/main.m (added) +++ lldb/trunk/packages/Python/lldbsuite/test/lang/objc/objc-foundation-dictionary-empty/main.m Wed Mar 14 17:07:05 2018 @@ -0,0 +1,7 @@ +#import <Foundation/Foundation.h> + +int main(void) +{ + NSDictionary *emptyDictionary = [[NSDictionary alloc] init]; + return 0; //% self.expect("frame var emptyDictionary", substrs = ["0 key/value pairs"]); +} _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits