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
e5b256e4
Commit
e5b256e4
authored
Jan 10, 2018
by
JC Brand
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix broken tests
parent
31e884f7
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
23 additions
and
12 deletions
+23
-12
CHANGES.md
CHANGES.md
+1
-0
package-lock.json
package-lock.json
+1
-1
spec/chatroom.js
spec/chatroom.js
+21
-11
No files found.
CHANGES.md
View file @
e5b256e4
...
...
@@ -5,6 +5,7 @@
### Bugfixes
-
#800 Could not register successfully in ejabberd 17.01
-
#949 Don't flash the roster contacts filter (i.e. hide by default)
-
#951 Duplicate messages received in an MUC chat room.
-
#953 MUC "Features" displayed when exiting configuration
-
#967 Rooms list doesn't show when the server doesn't support bookmarks
-
Don't require
`auto_login`
to be
`true`
when using the API to log in.
...
...
package-lock.json
View file @
e5b256e4
...
...
@@ -921,7 +921,7 @@
"dev"
:
true
},
"backbone.overview"
:
{
"version"
:
"git+https://github.com/jcbrand/Backbone.Overview.git#1
6239768880044f402edbdb1843220c44204cf15
"
,
"version"
:
"git+https://github.com/jcbrand/Backbone.Overview.git#1
c67a73be1f43cbb39fcd6b1b5d3cfc0ffdf2b5c
"
,
"dev"
:
true
,
"requires"
:
{
"backbone"
:
"1.3.3"
...
...
spec/chatroom.js
View file @
e5b256e4
...
...
@@ -75,9 +75,8 @@
test_utils
.
createContacts
(
_converse
,
'
current
'
);
test_utils
.
waitUntil
(
function
()
{
return
$
(
_converse
.
rosterview
.
el
).
find
(
'
.roster-group .group-toggle
'
).
length
;
},
300
)
.
then
(
function
()
{
return
$
(
_converse
.
rosterview
.
el
).
find
(
'
.roster-group .group-toggle
'
).
length
;
},
300
).
then
(
function
()
{
test_utils
.
openAndEnterChatRoom
(
_converse
,
'
lounge
'
,
'
localhost
'
,
'
dummy
'
).
then
(
function
()
{
var
jid
=
'
lounge@localhost
'
;
var
room
=
_converse
.
api
.
rooms
.
get
(
jid
);
...
...
@@ -289,6 +288,7 @@
});
describe
(
"
An instant chat room
"
,
function
()
{
it
(
"
will be created when muc_instant_rooms is set to true
"
,
mock
.
initConverseWithPromises
(
null
,
[
'
rosterGroupsFetched
'
],
{},
...
...
@@ -297,9 +297,17 @@
var
sent_IQ
,
IQ_id
;
var
sendIQ
=
_converse
.
connection
.
sendIQ
;
spyOn
(
_converse
.
connection
,
'
sendIQ
'
).
and
.
callFake
(
function
(
iq
,
callback
,
errback
)
{
sent_IQ
=
iq
;
IQ_id
=
sendIQ
.
bind
(
this
)(
iq
,
callback
,
errback
);
if
(
iq
.
nodeTree
.
getAttribute
(
'
to
'
)
===
'
lounge@localhost
'
)
{
sent_IQ
=
iq
;
IQ_id
=
sendIQ
.
bind
(
this
)(
iq
,
callback
,
errback
);
}
else
{
sendIQ
.
bind
(
this
)(
iq
,
callback
,
errback
);
}
});
test_utils
.
openChatRoom
(
_converse
,
'
lounge
'
,
'
localhost
'
,
'
dummy
'
);
// We pretend this is a new room, so no disco info is returned.
//
/* <iq from="jordie.langen@chat.example.org/converse.js-11659299" to="myroom@conference.chat.example.org" type="get">
* <query xmlns="http://jabber.org/protocol/disco#info"/>
* </iq>
...
...
@@ -309,10 +317,8 @@
* </error>
* </iq>
*/
test_utils
.
openChatRoom
(
_converse
,
'
lounge
'
,
'
localhost
'
,
'
dummy
'
);
// We pretend this is a new room, so no disco info is returned.
var
features_stanza
=
$iq
({
from
:
'
lounge@localhost
'
,
'
from
'
:
'
lounge@localhost
'
,
'
id
'
:
IQ_id
,
'
to
'
:
'
dummy@localhost/desktop
'
,
'
type
'
:
'
error
'
...
...
@@ -337,7 +343,7 @@
"
type='get' xmlns='jabber:client' id='
"
+
IQ_id
+
"
'>
"
+
"
<query xmlns='http://jabber.org/protocol/disco#info' node='x-roomuser-item'/></iq>
"
},
300
).
then
(
function
()
{
/*
*
<iq xmlns="jabber:client" type="error" to="jordie.langen@chat.example.org/converse.js-11659299" from="myroom@conference.chat.example.org">
/* <iq xmlns="jabber:client" type="error" to="jordie.langen@chat.example.org/converse.js-11659299" from="myroom@conference.chat.example.org">
* <error type="cancel">
* <item-not-found xmlns="urn:ietf:params:xml:ns:xmpp-stanzas"/>
* </error>
...
...
@@ -1238,8 +1244,12 @@
var
sent_IQ
,
IQ_id
;
var
sendIQ
=
_converse
.
connection
.
sendIQ
;
spyOn
(
_converse
.
connection
,
'
sendIQ
'
).
and
.
callFake
(
function
(
iq
,
callback
,
errback
)
{
sent_IQ
=
iq
;
IQ_id
=
sendIQ
.
bind
(
this
)(
iq
,
callback
,
errback
);
if
(
iq
.
nodeTree
.
getAttribute
(
'
to
'
)
===
'
lounge@localhost
'
)
{
sent_IQ
=
iq
;
IQ_id
=
sendIQ
.
bind
(
this
)(
iq
,
callback
,
errback
);
}
else
{
sendIQ
.
bind
(
this
)(
iq
,
callback
,
errback
);
}
});
test_utils
.
openChatRoom
(
_converse
,
'
lounge
'
,
'
localhost
'
,
'
dummy
'
);
...
...
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