Exemple #1
0
 def test_AD_tls(self):
     self.assertEqual(
         configTool.connect_ldap_server(self.AD_server_tls, None,
                                        self.AD_user, self.AD_pass, 'y',
                                        self.AD_server_tls_path)['message'],
         "Successfully connected!")
Exemple #2
0
 def test_connect_good_host_name(self):
     self.assertEqual(
         configTool.connect_ldap_server(self.good_host_name, None, "", "",
                                        'n', "")['message'],
         "Successfully connected!")
Exemple #3
0
 def test_bad_password(self):
     self.assertEqual(
         configTool.connect_ldap_server(self.AD_server, None, self.AD_user,
                                        self.bad_password, 'n',
                                        "")['message'],
         "Failed to bind to socket (Invalid Log in credentials)")
Exemple #4
0
 def test_connect_bad_host(self):
     self.assertEqual(
         configTool.connect_ldap_server(self.bad_host, None, "", "", 'n',
                                        "")['message'],
         "Failed to connect due to invalid socket.")
Exemple #5
0
 def test_connect_bad_port(self):
     self.assertEqual(
         configTool.connect_ldap_server(self.good_host_name, self.bad_port,
                                        "", "", 'n', "")['message'],
         "Invalid Port")
Exemple #6
0
 def test_connect_bad_host(self):
     self.assertEqual(configTool.connect_ldap_server(self.bad_host, None, "", "", 'n', "")['message'], "Failed to connect due to invalid socket.")
Exemple #7
0
 def test_AD_tls(self):
     self.assertEqual(configTool.connect_ldap_server(self.AD_server_tls, None, self.AD_user, self.AD_pass, 'y', self.AD_server_tls_path)['message'], "Successfully connected!")
Exemple #8
0
 def test_bad_password(self):
     self.assertEqual(configTool.connect_ldap_server(self.AD_server, None, self.AD_user, self.bad_password, 'n', "")['message'], "Failed to bind to socket (Invalid Log in credentials)")
Exemple #9
0
 def test_connect_good_host_name(self):
     self.assertEqual(configTool.connect_ldap_server(self.good_host_name, None, "", "", 'n', "")['message'], "Successfully connected!")
Exemple #10
0
 def test_connect_bad_port(self):
     self.assertEqual(configTool.connect_ldap_server(self.good_host_name, self.bad_port, "", "", 'n', "")['message'], "Invalid Port")