fixed up all of the data url isseus in the unit test suite

This commit is contained in:
Eric Rowell
2013-03-24 16:04:56 -07:00
parent 46c7b89e06
commit a3db78cc0f
4 changed files with 17 additions and 13 deletions

View File

@@ -97,7 +97,10 @@
*/
applyFilter: function(filter, config, callback) {
var image = this.getImage(),
canvas = new Kinetic.Canvas(image.width, image.height),
canvas = new Kinetic.Canvas({
width: image.width,
height: image.height
}),
context = canvas.getContext(),
that = this;

File diff suppressed because one or more lines are too long

View File

@@ -606,7 +606,7 @@ Test.Modules.CONTAINER = {
stage.toDataURL({
callback: function(dataUrl) {
//console.log(dataUrl)
warn(dataUrl === dataUrls['node shape type selector'], 'problem with node and shape type selector render.');
testDataUrl(dataUrl,'node shape type selector', 'problem with node and shape type selector render.');
}
});
},
@@ -864,7 +864,7 @@ Test.Modules.CONTAINER = {
stage.toDataURL({
callback: function(dataUrl) {
//console.log(dataUrl)
warn(dataUrls['blue on top of green'] === dataUrl, 'layer setZIndex is not working');
testDataUrl(dataUrl, 'blue on top of green', 'layer setZIndex is not working');
}
});
},
@@ -905,7 +905,7 @@ Test.Modules.CONTAINER = {
stage.toDataURL({
callback: function(dataUrl) {
warn(dataUrls['blue on top of green'] === dataUrl, 'layer moveToTop is not working');
testDataUrl(dataUrl, 'blue on top of green', 'layer moveToTop is not working');
}
});
},
@@ -946,7 +946,7 @@ Test.Modules.CONTAINER = {
stage.toDataURL({
callback: function(dataUrl) {
warn(dataUrls['blue on top of green'] === dataUrl, 'layer moveToBottom is not working');
testDataUrl(dataUrl, 'blue on top of green', 'layer moveToBottom is not working');
}
});
},
@@ -986,7 +986,7 @@ Test.Modules.CONTAINER = {
stage.toDataURL({
callback: function(dataUrl) {
warn(dataUrls['blue on top of green'] === dataUrl, 'layer moveDown is not working');
testDataUrl(dataUrl, 'blue on top of green', 'layer moveDown is not working');
}
});
},
@@ -1026,7 +1026,7 @@ Test.Modules.CONTAINER = {
stage.toDataURL({
callback: function(dataUrl) {
warn(dataUrls['blue on top of green'] === dataUrl, 'layer moveUp is not working');
testDataUrl(dataUrl, 'blue on top of green', 'layer moveUp is not working');
}
});
},

View File

@@ -187,7 +187,7 @@ Test.Modules.IMAGE = {
var hitDataUrl = layer.hitCanvas.toDataURL();
//console.log(hitDataUrl);
warn(hitDataUrl === dataUrls['transparent image hit render'], 'problem rendering image on hit graph');
testDataUrl(hitDataUrl,'transparent image hit render', 'problem rendering image on hit graph');
});
};
imageObj.src = '../assets/lion.png';
@@ -291,7 +291,7 @@ Test.Modules.IMAGE = {
layer.draw();
var dataUrl = layer.toDataURL();
//console.log(dataUrl);
warn(dataUrl === dataUrls['adjust image brightness'], 'problem with Brighten filter.');
testDataUrl(dataUrl, 'adjust image brightness', 'problem with Brighten filter.');
});
};
@@ -327,7 +327,7 @@ Test.Modules.IMAGE = {
layer.draw();
var dataUrl = layer.toDataURL();
//console.log(dataUrl);
warn(dataUrl === dataUrls['adjust image brightness'], 'problem with Brighten filter.');
testDataUrl(dataUrl, 'blur filter', 'problem with Blur filter.');
});
};