def METHOD_NAME(self):
    edges = {
        'r': ['a', 'i'],
        'a': ['b', 'c'],
        'b': ['c', 'e', 'g'],
        'c': ['d'],
        'd': ['i'],
        'e': ['c', 'f'],
        'f': ['i'],
        'g': ['h'],
        'h': ['d', 'f', 'i']
    }
    expected_dominators = {
        'r': None,
        'a': 'r',
        'b': 'a',
        'c': 'a',
        'd': 'a',
        'e': 'b',
        'f': 'b',
        'g': 'b',
        'h': 'g',
        'i': 'r'
    }
    self.graph.entry = 'r'
    self.graph.edges = edges
    self.graph.nodes = list(expected_dominators.keys())
    self.assertEqual(expected_dominators, self.graph.immediate_dominators())