Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / lldb / test / API / lang / objc / objc-new-syntax / TestObjCNewSyntaxDictionary.py
blob6e1622432f4c4e44a20e7936b1ba25e4e9c9bc54
1 """Test that the Objective-C syntax for dictionary/array literals and indexing works"""
4 import lldb
5 from lldbsuite.test.decorators import *
6 from lldbsuite.test.lldbtest import *
7 from lldbsuite.test import lldbutil
9 from ObjCNewSyntaxTest import ObjCNewSyntaxTest
12 class ObjCNewSyntaxTestCaseDictionary(ObjCNewSyntaxTest):
13 @skipIf(macos_version=["<", "10.12"])
14 @expectedFailureAll(archs=["i[3-6]86"])
15 def test_read_dictionary(self):
16 self.runToBreakpoint()
18 self.expect(
19 'expr --object-description -- immutable_dictionary[@"key"]',
20 VARIABLES_DISPLAYED_CORRECTLY,
21 substrs=["value"],
24 self.expect(
25 'expr --object-description -- mutable_dictionary[@"key"]',
26 VARIABLES_DISPLAYED_CORRECTLY,
27 substrs=["value"],
30 @skipIf(macos_version=["<", "10.12"])
31 @expectedFailureAll(archs=["i[3-6]86"])
32 def test_update_dictionary(self):
33 self.runToBreakpoint()
35 self.expect(
36 'expr --object-description -- mutable_dictionary[@"key"] = @"object"',
37 VARIABLES_DISPLAYED_CORRECTLY,
38 substrs=["object"],
41 self.expect(
42 'expr --object-description -- mutable_dictionary[@"key"]',
43 VARIABLES_DISPLAYED_CORRECTLY,
44 substrs=["object"],
47 @skipIf(macos_version=["<", "10.12"])
48 @expectedFailureAll(archs=["i[3-6]86"])
49 def test_dictionary_literal(self):
50 self.runToBreakpoint()
52 self.expect(
53 'expr --object-description -- @{ @"key" : @"object" }',
54 VARIABLES_DISPLAYED_CORRECTLY,
55 substrs=["key", "object"],