mirror of
https://github.com/publiclab/image-sequencer.git
synced 2025-12-15 12:50:04 +01:00
an actual test of addStep()
This commit is contained in:
@@ -3,7 +3,7 @@ Image Sequencer
|
|||||||
|
|
||||||
aka "Consequencer"
|
aka "Consequencer"
|
||||||
|
|
||||||

|
[](https://travis-ci.org/jywarren/image-sequencer)
|
||||||
|
|
||||||
## Why
|
## Why
|
||||||
|
|
||||||
|
|||||||
149802
dist/image-sequencer.js
vendored
149802
dist/image-sequencer.js
vendored
File diff suppressed because one or more lines are too long
@@ -6,7 +6,7 @@ module.exports = {
|
|||||||
'image-select': require('./modules/ImageSelect'),
|
'image-select': require('./modules/ImageSelect'),
|
||||||
'green-channel': require('./modules/GreenChannel'),
|
'green-channel': require('./modules/GreenChannel'),
|
||||||
'ndvi-red': require('./modules/NdviRed'),
|
'ndvi-red': require('./modules/NdviRed'),
|
||||||
// 'plot': require('./modules/Plot'),
|
'plot': require('./modules/Plot'),
|
||||||
'image-threshold': require('./modules/ImageThreshold')
|
'image-threshold': require('./modules/ImageThreshold')
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -11,6 +11,9 @@ require('../dist/image-sequencer.js');
|
|||||||
var sequencer = ImageSequencer({
|
var sequencer = ImageSequencer({
|
||||||
defaultSteps: function() {
|
defaultSteps: function() {
|
||||||
console.log('defaults');
|
console.log('defaults');
|
||||||
|
},
|
||||||
|
ui: {
|
||||||
|
create: function() {}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -27,3 +30,18 @@ test('Image Sequencer has tests', function (t) {
|
|||||||
t.equal(true, true);
|
t.equal(true, true);
|
||||||
t.end();
|
t.end();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
test('addStep adds a step', function (t) {
|
||||||
|
t.equal(sequencer.steps.length, 0);
|
||||||
|
sequencer.addStep('ndvi-red');
|
||||||
|
t.equal(sequencer.steps.length, 1);
|
||||||
|
t.end();
|
||||||
|
});
|
||||||
|
|
||||||
|
//test('test each module', function (t) {
|
||||||
|
// steps.forEach(function(step, i) {
|
||||||
|
// t.equal(step.test(step.testInput),step.testOutput);
|
||||||
|
// // or check that it's equal with a diff method?
|
||||||
|
// // we could also test each type of output
|
||||||
|
// });
|
||||||
|
//});
|
||||||
|
|||||||
Reference in New Issue
Block a user