function testDrag(opts) {
                    makeUI("#0000ff");
                    eventAtRatio("mousedown", colorEditor[opts.item], opts.clickAt);
                    eventAtRatio("mousemove", colorEditor[opts.item], opts.dragTo);
                    checkNear(tinycolor(colorEditor.getColor()).toHsv()[opts.param], opts.expected, opts.tolerance);
                    colorEditor[opts.item].trigger("mouseup");  // clean up drag state
                }
Test a drag event on the given UI element.
@param {object} opts The parameters to test:
    item: The (string) name of the member of ColorEditor that references the element to test.
    clickAt: An [x, y] array specifying the simulated x/y mouse position for the initial mouse down
         as a fraction of the item's width/height. For example, [0.5, 0.5] would specify a click
         exactly in the center of the element.
    dragTo: An [x, y] array specifying the location to drag to, using the same convention as clickAt.
    param: The (string) parameter whose value we're testing (h, s, v, or a).
    expected: The expected value for the parameter.
    tolerance: The tolerance in variation for the expected value.