def METHOD_NAME():
    """Test zoom with both ratio and limits set"""
    vb = pg.ViewBox(lockAspect=1)
    # twice as wide as tall
    vb.setFixedHeight(10)
    vb.setFixedWidth(20)
    # set some limits
    vb.setLimits(xMin=-5, xMax=5, yMin=-5, yMax=5)
    # Try to zoom too tall
    testRange = pg.QtCore.QRect(0, 0, 6, 10)
    vb.setRange(testRange, padding=0)
    viewRange = vb.getState()['viewRange']
    viewWidth = viewRange[0][1] - viewRange[0][0]
    viewHeight = viewRange[1][1] - viewRange[1][0]
    # Make sure our view is within limits and the proper aspect ratio
    assert viewRange[0][0] >= -5
    assert viewRange[0][1] <= 5
    assert viewRange[1][0] >= -5
    assert viewRange[1][1] <= 5
    assert viewWidth == 2 * viewHeight