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>
llvm-svn: 327592
+++ /dev/null
-breakpoint set --file NSDict.m --line 8
-run
-frame var
+++ /dev/null
-#include <Foundation/Foundation.h>
-
-int main(void)
-{
- NSDictionary *emptyDictionary = [[NSDictionary alloc] init];
- NSMutableDictionary *mutableDictionary = [NSMutableDictionary dictionary];
- NSDictionary *dictionary = @{ @"key": @{} };
- return 0;
-}
+++ /dev/null
-# Test that foundation NSDictionary0 is formatted correctly (the summary).
-# Foundation is only available on Darwin so just restrict the test to run there.
-# REQUIRES: darwin
-# RUN: %cc %p/Inputs/NSDict.m -framework Foundation -g -o %t && %lldb -b \
-# RUN: -s %p/Inputs/NSDict.commands -- %t 2>&1 | FileCheck %s
-
-# CHECK: (__NSDictionary0 *) emptyDictionary = {{.*}} 0 key/value pairs
+++ /dev/null
-config.suffixes = ['.test']
--- /dev/null
+from lldbsuite.test import lldbinline
+from lldbsuite.test import decorators
+
+lldbinline.MakeInlineTest(
+ __file__, globals(), [
+ decorators.skipIfFreeBSD, decorators.skipIfLinux, decorators.skipIfWindows])
--- /dev/null
+#import <Foundation/Foundation.h>
+
+int main(void)
+{
+ NSDictionary *emptyDictionary = [[NSDictionary alloc] init];
+ return 0; //% self.expect("frame var emptyDictionary", substrs = ["0 key/value pairs"]);
+}