def METHOD_NAME(self):
    edges = {
        'r': ['w', 'y'],
        'w': ['x1'],
        'y': ['x7'],
        'x1': ['x2'],
        'x2': ['x1', 'x3'],
        'x3': ['x2', 'x4'],
        'x4': ['x3', 'x5'],
        'x5': ['x4', 'x6'],
        'x6': ['x5', 'x7'],
        'x7': ['x6']
    }
    expected_dominators = {
        'r': None,
        'w': 'r',
        'y': 'r',
        'x1': 'r',
        'x2': 'r',
        'x3': 'r',
        'x4': 'r',
        'x5': 'r',
        'x6': 'r',
        'x7': 'r'
    }
    self.graph.entry = 'r'
    self.graph.edges = edges
    self.graph.nodes = list(expected_dominators.keys())
    self.assertEqual(expected_dominators, self.graph.immediate_dominators())