コード例 #1
0
ファイル: changeme_tests.py プロジェクト: hbxc0re/changeme
    def test_check_form_zabbix_fail(self):
        responses.add(** mock.zabbix_fail)

        cred = self.get_cred('Zabbix')
        assert cred['name'] == 'Zabbix'

        matches = changeme.check_form(mock.zabbix_auth['url'], cred, False, False)
        assert len(matches) == 0
コード例 #2
0
    def test_check_form_zabbix_fail(self):
        responses.add(**mock.zabbix_fail)

        cred = self.get_cred('Zabbix')
        assert cred['name'] == 'Zabbix'

        matches = changeme.check_form(mock.zabbix_auth['url'], cred, False,
                                      False)
        assert len(matches) == 0
コード例 #3
0
    def test_check_form_jboss_fail(self):
        responses.add(**mock.tomcat_fp)

        cred = self.get_cred(self.jboss_name)
        assert cred['name'] == self.jboss_name

        matches = changeme.check_form(mock.jboss_fp['url'], cred,
                                      {'JSESSIONID': 'foobar'}, 'foobar')

        assert matches is None
コード例 #4
0
    def test_check_form_jboss(self):
        responses.add(**mock.jboss_auth)

        cred = self.get_cred(self.jboss_name)
        assert cred['name'] == self.jboss_name

        matches = changeme.check_form(mock.jboss_fp['url'], cred,
                                      {'JSESSIONID': 'foobar'}, 'foobar')

        assert len(matches) > 0
コード例 #5
0
ファイル: changeme_tests.py プロジェクト: hbxc0re/changeme
    def test_check_form_jboss_fail(self):
        responses.add(** mock.tomcat_fp)

        cred = self.get_cred(self.jboss_name)
        assert cred['name'] == self.jboss_name

        matches = changeme.check_form(
                            mock.jboss_fp['url'],
                            cred,
                            {'JSESSIONID': 'foobar'},
                            'foobar')

        assert matches is None
コード例 #6
0
ファイル: changeme_tests.py プロジェクト: hbxc0re/changeme
    def test_check_form_jboss(self):
        responses.add(** mock.jboss_auth)

        cred = self.get_cred(self.jboss_name)
        assert cred['name'] == self.jboss_name

        matches = changeme.check_form(
                            mock.jboss_fp['url'],
                            cred,
                            {'JSESSIONID': 'foobar'},
                            'foobar')

        assert len(matches) > 0