mirror of
https://github.com/publiclab/image-sequencer.git
synced 2025-12-11 19:00:00 +01:00
* wasmSuccess * modules use wasmSuccess * modules use wasmSuccess * add the tooltip * add GIF support * fix imageDImensions function * fix inputCoordinatesParser function * show correct image dimensions * show correct image dimensions * don't allow save as PDF for GIFs * fix QR module * fix BlobAnalysis * fix Blur * fix Colorbar * fix Crop * fix crop defaults * fix DrawRectangle * fix EdgeDetect * fix FlipImage * fix Gradient * fix Invert * fix Overlay * fix Resize * fix Rotate * fix TextOverlay * fix parse input test * make GIFs work in nodejs * sample GIF test * small change * cleanup * cleanup * cleanup * small fix * small change * handle errors * proper error handling and fix tests * cleanup * try a fix * try another fix * fix module benchmarks * try more fixes * revert * try fixing the tests * fix overlay test * add the gif tests * remove unnecessary changes * fix tests * whoops * add some docs * inBrowser * fix all module tests Co-authored-by: Jeffrey Warren <jeff@unterbahn.com>
19 lines
579 B
JavaScript
19 lines
579 B
JavaScript
var test = require('tape');
|
|
|
|
var parseCornerCoordinateInputs = require('../../../src/util/ParseInputCoordinates');
|
|
|
|
|
|
test('parseCornerCoordinateInputs works.', function (t) {
|
|
var options = { x: '10%', iw: 10, ih: 10 },
|
|
coord = { x: { valInp: options.x, type: 'horizontal' } };
|
|
|
|
callback = function (options, coord) {
|
|
options.x = parseInt(coord.x.valInp);
|
|
t.equal(options.x, 1, 'parseCornerCootesrdinateInputs Works.');
|
|
t.equal(typeof options.x, 'number', 'Correct output type');
|
|
t.end();
|
|
};
|
|
|
|
parseCornerCoordinateInputs(options, coord, callback);
|
|
});
|