Commit b681a950 authored by Romain Courteaud's avatar Romain Courteaud

Ensure unicode is correctly handled by the scenario

parent 5ccc2bd8
...@@ -94,7 +94,7 @@ ...@@ -94,7 +94,7 @@
// sub_storage: { // sub_storage: {
// "type": "dropbox", // "type": "dropbox",
// "access_token" : "TOKEN", // "access_token" : "TOKEN",
// "root" : "dropbox" // "root" : "dropbox"
// } // }
// } // }
// } // }
...@@ -244,20 +244,20 @@ ...@@ -244,20 +244,20 @@
}) })
.then(function () { .then(function () {
return jio.put("test.txt", {}); return jio.put("foo❤/test.txt", {});
}) })
.then(function () { .then(function () {
return jio.putAttachment( return jio.putAttachment(
"test.txt", "foo❤/test.txt",
"enclosure", "enclosure",
new Blob(["fooé\nbar"], {type: "text/plain"}) new Blob(["fooé\nbar测试四😈"], {type: "text/plain"})
); );
}) })
.then(function () { .then(function () {
ok(true, "Attachment stored"); ok(true, "Attachment stored");
return jio.getAttachment("test.txt", "enclosure"); return jio.getAttachment("foo❤/test.txt", "enclosure");
}) })
.then(function (blob) { .then(function (blob) {
...@@ -265,14 +265,14 @@ ...@@ -265,14 +265,14 @@
}) })
.then(function (result) { .then(function (result) {
equal(result.target.result, "fooé\nbar", "Attachment correctly fetched"); equal(result.target.result, "fooé\nbar测试四😈", "Attachment correctly fetched");
return jio.get("test.txt"); return jio.get("foo❤/test.txt");
}) })
.then(function (doc) { .then(function (doc) {
deepEqual(doc, {}, "Document correctly fetched"); deepEqual(doc, {}, "Document correctly fetched");
return jio.allAttachments("test.txt"); return jio.allAttachments("foo❤/test.txt");
}) })
.then(function (doc) { .then(function (doc) {
deepEqual(doc, { deepEqual(doc, {
...@@ -280,7 +280,7 @@ ...@@ -280,7 +280,7 @@
}, },
"Attachment list correctly fetched"); "Attachment list correctly fetched");
return jio.removeAttachment("test.txt", "enclosure"); return jio.removeAttachment("foo❤/test.txt", "enclosure");
}) })
.then(function () { .then(function () {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment