Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
converse.js
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
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
converse.js
Commits
c24e7227
Commit
c24e7227
authored
5 years ago
by
JC Brand
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix testing bug where all subsequent tests after a timed out test also time out
parent
d58380af
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
5 deletions
+4
-5
tests/mock.js
tests/mock.js
+4
-5
No files found.
tests/mock.js
View file @
c24e7227
...
...
@@ -250,11 +250,11 @@
return
_converse
;
}
mock
.
initConverse
=
function
(
spies
,
promise_names
=
null
,
settings
=
null
,
func
)
{
mock
.
initConverse
=
function
(
spies
,
promise_names
=
[]
,
settings
=
null
,
func
)
{
if
(
_
.
isFunction
(
spies
))
{
func
=
spies
;
spies
=
null
;
promise_names
=
null
promise_names
=
[]
settings
=
null
;
}
return
async
done
=>
{
...
...
@@ -263,9 +263,8 @@
_converse
.
api
.
user
.
logout
();
done
();
}
const
promises
=
_
.
map
(
promise_names
,
_converse
.
api
.
waitUntil
);
await
Promise
.
all
(
promises
);
func
(
_done
,
_converse
);
await
Promise
.
all
(
promise_names
.
map
(
_converse
.
api
.
waitUntil
));
func
(
_done
,
_converse
).
catch
(
e
=>
{
fail
(
e
);
_done
();
});
}
};
return
mock
;
...
...
This diff is collapsed.
Click to expand it.
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