chg: [testing] testing

testing8
iglocska 2024-09-05 10:17:27 +02:00
parent bc96756ef7
commit e612a97a02
No known key found for this signature in database
GPG Key ID: BEA224F1FEF113AC
1 changed files with 2 additions and 0 deletions

View File

@ -1174,6 +1174,7 @@ class TestComprehensive(unittest.TestCase):
second.set_date('2018-09-01')
second.add_attribute('ip-src', '8.8.8.8')
try:
self.admin_misp_connector.set_server_setting('MISP.background_jobs', False, force=True)
first = self.user_misp_connector.add_event(first)
print(first.to_json())
second = self.user_misp_connector.add_event(second)
@ -1187,6 +1188,7 @@ class TestComprehensive(unittest.TestCase):
first = self.user_misp_connector.update_event(first)
print(first.to_json())
print(self.admin_misp_connector.publish(first, alert=False))
self.admin_misp_connector.set_server_setting('MISP.background_jobs', True, force=True)
time.sleep(5)
csv = self.user_misp_connector.search(return_format='csv', publish_timestamp=first.timestamp.timestamp())
self.assertEqual(len(csv), 1)