Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
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
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
7f5d86d8
Commit
7f5d86d8
authored
Sep 10, 2019
by
Illya Klymov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix FormData usage in karma tests
parent
4d542db5
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
7 deletions
+4
-7
spec/javascripts/blob/blob_file_dropzone_spec.js
spec/javascripts/blob/blob_file_dropzone_spec.js
+1
-4
spec/javascripts/dropzone_input_spec.js
spec/javascripts/dropzone_input_spec.js
+3
-3
No files found.
spec/javascripts/blob/blob_file_dropzone_spec.js
View file @
7f5d86d8
...
...
@@ -24,10 +24,7 @@ describe('BlobFileDropzone', function() {
it
(
'
is disabled while uploading
'
,
()
=>
{
spyOn
(
window
,
'
alert
'
);
const
file
=
{
name
:
'
some-file.jpg
'
,
type
:
'
jpg
'
,
};
const
file
=
new
File
([],
'
some-file.jpg
'
);
const
fakeEvent
=
$
.
Event
(
'
drop
'
,
{
dataTransfer
:
{
files
:
[
file
]
},
});
...
...
spec/javascripts/dropzone_input_spec.js
View file @
7f5d86d8
...
...
@@ -2,9 +2,9 @@ import $ from 'jquery';
import
dropzoneInput
from
'
~/dropzone_input
'
;
import
{
TEST_HOST
}
from
'
spec/test_constants
'
;
const
TEST_FILE
=
{
upload
:
{},
};
const
TEST_FILE
=
new
File
([],
'
somefile.jpg
'
);
TEST_FILE
.
upload
=
{};
const
TEST_UPLOAD_PATH
=
`
${
TEST_HOST
}
/upload/file`
;
const
TEST_ERROR_MESSAGE
=
'
A big error occurred!
'
;
const
TEMPLATE
=
`<form class="gfm-form" data-uploads-path="
${
TEST_UPLOAD_PATH
}
">
...
...
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