Permalink
Browse files

Add a test for JPEG-XR export

  • Loading branch information...
1 parent f1bd18c commit d3893725795ee688a970d93bf884b02935474251 @NielsLeenheer NielsLeenheer committed Nov 27, 2013
Showing with 19 additions and 0 deletions.
  1. +3 −0 scripts/data.js
  2. +16 −0 scripts/engine.js
View
@@ -1453,6 +1453,9 @@ var tests = [
}, {
id: 'jpeg',
name: 'JPEG support'
+ }, {
+ id: 'jpegxr',
+ name: 'JPEG-XR support'
}, {
id: 'webp',
name: 'WebP support'
View
@@ -838,6 +838,22 @@ Test = (function() {
});
+ var passed = false;
+ if (this.canvas.getContext) {
+ try {
+ passed = this.canvas.toDataURL('image/vnd.ms-photo').substring(5,23) == 'image/vnd.ms-photo';
+ }
+ catch(e) {
+ }
+ }
+
+ this.section.setItem({
+ id: 'jpegxr',
+ passed: passed,
+ value: 0
+ });
+
+
var passed = false;
if (this.canvas.getContext) {
try {

0 comments on commit d389372

Please sign in to comment.