コード例 #1
0
    def test_check_dns_wildcard_should_return_a_boolean(self):
        """
        Test checkDnsWildcard(self, target)
        """
        sf = SpiderFoot(self.default_options)

        check_dns_wildcard = sf.checkDnsWildcard('local')
        self.assertEqual(bool, type(check_dns_wildcard))
コード例 #2
0
    def test_check_dns_wildcard_invalid_target_should_return_none(self):
        """
        Test checkDnsWildcard(self, target)
        """
        sf = SpiderFoot(self.default_options)

        check_dns_wildcard = sf.checkDnsWildcard(None)
        self.assertEqual(bool, type(check_dns_wildcard))
コード例 #3
0
    def test_check_dns_wildcard_should_return_a_boolean(self):
        """
        Test checkDnsWildcard(self, target)
        """
        sf = SpiderFoot(dict())

        check_dns_wildcard = sf.checkDnsWildcard(None)
        self.assertEqual(bool, type(check_dns_wildcard))
コード例 #4
0
    def test_check_dns_wildcard_invalid_target_should_return_none(self):
        """
        Test checkDnsWildcard(self, target)
        """
        sf = SpiderFoot(self.default_options)

        invalid_types = [None, "", list(), dict()]
        for invalid_type in invalid_types:
            with self.subTest(invalid_type=invalid_type):
                check_dns_wildcard = sf.checkDnsWildcard(invalid_type)
                self.assertIsInstance(check_dns_wildcard, bool)