Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
J
jio
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Romain Courteaud
jio
Commits
af5c85a2
Commit
af5c85a2
authored
Mar 28, 2017
by
Tristan Cavelier
Committed by
Romain Courteaud
Mar 29, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
erp5storage: putAttachment returns xhr.responseType blob
/reviewed-on
nexedi/jio!50
parent
d0a43f62
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
3 deletions
+7
-3
src/jio.storage/erp5storage.js
src/jio.storage/erp5storage.js
+1
-0
test/jio.storage/erp5storage.tests.js
test/jio.storage/erp5storage.tests.js
+6
-3
No files found.
src/jio.storage/erp5storage.js
View file @
af5c85a2
...
@@ -437,6 +437,7 @@
...
@@ -437,6 +437,7 @@
"
type
"
:
"
POST
"
,
"
type
"
:
"
POST
"
,
"
url
"
:
name
,
"
url
"
:
name
,
"
data
"
:
data
,
"
data
"
:
data
,
"
dataType
"
:
"
blob
"
,
"
xhrFields
"
:
{
"
xhrFields
"
:
{
withCredentials
:
true
withCredentials
:
true
}
}
...
...
test/jio.storage/erp5storage.tests.js
View file @
af5c85a2
...
@@ -490,7 +490,7 @@
...
@@ -490,7 +490,7 @@
},
""
]);
},
""
]);
stop
();
stop
();
expect
(
1
1
);
expect
(
1
2
);
this
.
jio
.
putAttachment
(
this
.
jio
.
putAttachment
(
id
,
id
,
...
@@ -502,6 +502,7 @@
...
@@ -502,6 +502,7 @@
equal
(
server
.
requests
[
0
].
method
,
"
POST
"
);
equal
(
server
.
requests
[
0
].
method
,
"
POST
"
);
equal
(
server
.
requests
[
0
].
url
,
submit_url
);
equal
(
server
.
requests
[
0
].
url
,
submit_url
);
equal
(
server
.
requests
[
0
].
status
,
204
);
equal
(
server
.
requests
[
0
].
status
,
204
);
equal
(
server
.
requests
[
0
].
responseType
,
"
blob
"
);
ok
(
server
.
requests
[
0
].
requestBody
instanceof
FormData
);
ok
(
server
.
requests
[
0
].
requestBody
instanceof
FormData
);
ok
(
context
.
spy
.
calledTwice
,
"
FormData.append count
"
+
ok
(
context
.
spy
.
calledTwice
,
"
FormData.append count
"
+
...
@@ -536,7 +537,7 @@
...
@@ -536,7 +537,7 @@
},
""
]);
},
""
]);
stop
();
stop
();
expect
(
1
1
);
expect
(
1
2
);
this
.
jio
.
putAttachment
(
this
.
jio
.
putAttachment
(
id
,
id
,
...
@@ -548,6 +549,7 @@
...
@@ -548,6 +549,7 @@
equal
(
server
.
requests
[
0
].
method
,
"
POST
"
);
equal
(
server
.
requests
[
0
].
method
,
"
POST
"
);
equal
(
server
.
requests
[
0
].
url
,
submit_url
);
equal
(
server
.
requests
[
0
].
url
,
submit_url
);
equal
(
server
.
requests
[
0
].
status
,
204
);
equal
(
server
.
requests
[
0
].
status
,
204
);
equal
(
server
.
requests
[
0
].
responseType
,
"
blob
"
);
ok
(
server
.
requests
[
0
].
requestBody
instanceof
FormData
);
ok
(
server
.
requests
[
0
].
requestBody
instanceof
FormData
);
ok
(
context
.
spy
.
calledTwice
,
"
FormData.append count
"
+
ok
(
context
.
spy
.
calledTwice
,
"
FormData.append count
"
+
...
@@ -586,7 +588,7 @@
...
@@ -586,7 +588,7 @@
},
""
]);
},
""
]);
stop
();
stop
();
expect
(
1
2
);
expect
(
1
3
);
this
.
jio
.
putAttachment
(
this
.
jio
.
putAttachment
(
id
,
id
,
...
@@ -598,6 +600,7 @@
...
@@ -598,6 +600,7 @@
equal
(
server
.
requests
[
0
].
method
,
"
POST
"
);
equal
(
server
.
requests
[
0
].
method
,
"
POST
"
);
equal
(
server
.
requests
[
0
].
url
,
submit_url
);
equal
(
server
.
requests
[
0
].
url
,
submit_url
);
equal
(
server
.
requests
[
0
].
status
,
204
);
equal
(
server
.
requests
[
0
].
status
,
204
);
equal
(
server
.
requests
[
0
].
responseType
,
"
blob
"
);
ok
(
server
.
requests
[
0
].
requestBody
instanceof
FormData
);
ok
(
server
.
requests
[
0
].
requestBody
instanceof
FormData
);
ok
(
context
.
spy
.
calledOnce
,
"
FormData.append count
"
+
ok
(
context
.
spy
.
calledOnce
,
"
FormData.append count
"
+
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment