'Test the depth of references search.'

def test_depthLimit(self):

    a = []
    b = [a]
    c = [a, b]
    d = [a, c]
    self.assertEqual(['[0]'], reflect.objgrep(d, a, reflect.isSame, maxDepth=1))
    self.assertEqual(['[0]', '[1][0]'], reflect.objgrep(d, a, reflect.isSame, maxDepth=2))
    self.assertEqual(['[0]', '[1][0]', '[1][1][0]'], reflect.objgrep(d, a, reflect.isSame, maxDepth=3))
