summaryrefslogtreecommitdiff
path: root/tests/end_to_end
diff options
context:
space:
mode:
authorlouiz’ <louiz@louiz.org>2016-12-14 18:20:57 +0100
committerlouiz’ <louiz@louiz.org>2016-12-14 18:20:57 +0100
commitf512c9c666b2c629e8b9af29ec65c534e536e749 (patch)
treef8fd1c774c95d4f2ce787cff79971e51d471295f /tests/end_to_end
parentca8618941240545f76fd8ec32e7acb31226ab2d6 (diff)
downloadbiboumi-f512c9c666b2c629e8b9af29ec65c534e536e749.tar.gz
biboumi-f512c9c666b2c629e8b9af29ec65c534e536e749.tar.bz2
biboumi-f512c9c666b2c629e8b9af29ec65c534e536e749.tar.xz
biboumi-f512c9c666b2c629e8b9af29ec65c534e536e749.zip
e2e: test connection failure
Diffstat (limited to 'tests/end_to_end')
-rw-r--r--tests/end_to_end/__main__.py14
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/end_to_end/__main__.py b/tests/end_to_end/__main__.py
index fc55eaf..4dc61ba 100644
--- a/tests/end_to_end/__main__.py
+++ b/tests/end_to_end/__main__.py
@@ -468,6 +468,20 @@ if __name__ == '__main__':
"<presence from='{jid_one}/{resource_one}' to='#foo%{irc_server_one}/{nick_one}' />"),
connection_sequence("irc.localhost", '{jid_one}/{resource_one}'),
]),
+ Scenario("irc_server_connection_failure",
+ [
+ handshake_sequence(),
+ partial(send_stanza,
+ "<presence from='{jid_one}/{resource_one}' to='#foo%doesnotexist@{biboumi_host}/{nick_one}' />"),
+ partial(expect_stanza,
+ "/message/body[text()='Connecting to doesnotexist:6697 (encrypted)']"),
+ partial(expect_stanza,
+ "/message/body[text()='Connection failed: Domain name not found']"),
+ partial(expect_stanza,
+ ("/presence[@from='#foo%doesnotexist@{biboumi_host}/{nick_one}']/muc:x",
+ "/presence/error[@type='cancel']/stanza:item-not-found",
+ "/presence/error[@type='cancel']/stanza:text[text()='Domain name not found']")),
+ ]),
Scenario("simple_channel_join",
[
handshake_sequence(),