aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorAris Adamantiadis <aris@0xbadc0de.be>2010-05-10 11:08:32 +0200
committerAris Adamantiadis <aris@0xbadc0de.be>2010-05-10 11:08:32 +0200
commit9294c3284c4a656ad0f7d0f04c8760e23382e80b (patch)
tree6269f94879823d13fdbea71f11118a83beef0d1c /tests
parent9278dc0666de70f11b459e5b80e0c2ab6bbbe54c (diff)
downloadlibssh-9294c3284c4a656ad0f7d0f04c8760e23382e80b.tar.gz
libssh-9294c3284c4a656ad0f7d0f04c8760e23382e80b.tar.xz
libssh-9294c3284c4a656ad0f7d0f04c8760e23382e80b.zip
Changed test name + test with invalid proxycommand
Diffstat (limited to 'tests')
-rw-r--r--tests/unittests/torture_proxycommand.c19
1 files changed, 18 insertions, 1 deletions
diff --git a/tests/unittests/torture_proxycommand.c b/tests/unittests/torture_proxycommand.c
index d289019b..8bc601c3 100644
--- a/tests/unittests/torture_proxycommand.c
+++ b/tests/unittests/torture_proxycommand.c
@@ -27,11 +27,28 @@ START_TEST (torture_options_set_proxycommand)
}
END_TEST
+START_TEST (torture_options_set_proxycommand_notexist)
+{
+ int rc;
+
+ rc = ssh_options_set(session, SSH_OPTIONS_HOST, "localhost");
+ ck_assert(rc == 0);
+
+ rc = ssh_options_set(session, SSH_OPTIONS_PROXYCOMMAND, "this_command_does_not_exist");
+ ck_assert(rc == SSH_OK);
+ rc = ssh_connect(session);
+ ck_assert_msg(rc== SSH_ERROR);
+}
+END_TEST
+
static Suite *torture_make_suite(void) {
- Suite *s = suite_create("libssh_keyfiles");
+ Suite *s = suite_create("libssh_proxycommand");
torture_create_case_fixture(s, "torture_options_set_proxycommand",
torture_options_set_proxycommand, setup, teardown);
+ torture_create_case_fixture(s, "torture_options_set_proxycommand_notexist",
+ torture_options_set_proxycommand_notexist, setup, teardown);
+
return s;
}