fix: Travis tests should be happy now

pull/340/head
chrisr3d 2019-10-04 17:22:32 +02:00
parent 6bcd60871c
commit b9b78d1606
No known key found for this signature in database
GPG Key ID: 6BBED1B63A6D639F
2 changed files with 2 additions and 2 deletions

View File

@ -20,7 +20,7 @@ def handler(q=False):
misperrors['error'] = 'Vulnerability id missing'
return misperrors
api_url = check_url(request['config']['custom_API']) if request['config'].get('custom_API') else cveapi_url
api_url = check_url(request['config']['custom_API']) if request.get('config') and request['config'].get('custom_API') else cveapi_url
r = requests.get("{}{}".format(api_url, request.get('vulnerability')))
if r.status_code == 200:
vulnerability = json.loads(r.text)

View File

@ -50,7 +50,7 @@ class TestExpansions(unittest.TestCase):
def test_greynoise(self):
query = {"module": "greynoise", "ip-dst": "1.1.1.1"}
response = self.misp_modules_post(query)
self.assertTrue(self.get_values(response).strartswith('{"ip":"1.1.1.1","status":"ok"'))
self.assertTrue(self.get_values(response).startswith('{"ip":"1.1.1.1","status":"ok"'))
def test_ipasn(self):
query = {"module": "ipasn", "ip-dst": "1.1.1.1"}