Exemple #1
0
 def test_process_trackers_search(self):
     """Test processing component data."""
     payload = {'query': 'UA-49901229', 'type': 'GoogleAnalyticsAccountNumber'}
     response = self.client.search_trackers(**payload)
     wrapped = AttributeResponse(response)
     record = wrapped.get_records().pop(0)
     assert not (record.everBlacklisted)
     assert (record.alexaRank) == 38
     assert (record.hostname) == 'demo.paypal.com'
Exemple #2
0
 def test_process_components(self):
     """Test processing component data."""
     payload = {'query': 'passivetotal.org'}
     response = self.client.get_host_attribute_components(**payload)
     wrapped = AttributeResponse(response)
     record = wrapped.get_records().pop(0)
     assert (record.hostname) == 'passivetotal.org'
     assert (record.lastSeen) == '2016-01-07 21:52:30'
     assert (record.category) == 'JavaScript Library'
     assert (record.firstSeen) == '2015-12-26 11:17:43'
     assert (record.label) == 'jQuery'
Exemple #3
0
 def test_process_trackers(self):
     """Test processing tracker data."""
     payload = {'query': 'passivetotal.org'}
     response = self.client.get_host_attribute_trackers(**payload)
     wrapped = AttributeResponse(response)
     record = wrapped.get_records().pop(0)
     assert (record.hostname) == 'passivetotal.org'
     assert (record.lastSeen) == '2016-01-26 13:47:45'
     assert (record.attributeType) == 'GoogleAnalyticsAccountNumber'
     assert (record.firstSeen) == '2015-10-09 17:05:38'
     assert (record.attributeValue) == 'UA-61048133'