<commit_before>import datetime
from django.test import TestCase
from api.models import Event
from api.processors import get_pending_events

class EventTestCase(TestCase):
	def setUp(self):
		Event.objects.create(organizer="asdasd",title="asdasd",
							description="asdsad",location="asdsad",
							start_date=datetime.datetime.now(),end_date=datetime.datetime.now(),
							event_url="http://eee.com",contact_person="<EMAIL>",country="SI",
							pub_date=datetime.datetime.now())

	def test_get_approved_events(self):
		test_event = Event.objects.get(title="asdasd")
		self.assertEqual("PENDING", test_event.status)
		test_event.status = "APPROVED"
		test_event.save()
		self.assertEqual("APPROVED", test_event.status)

	def test_get_pending_events(self):
		events = get_pending_events()
		self.assertEqual(1, len(events))<commit_msg>some PEP8 fixes on the test in api<commit_after>import datetime
from django.test import TestCase
from api.models import Event
from api.processors import get_pending_events


class EventTestCase(TestCase):
	def setUp(self):
		Event.objects.create(
			organizer="asdasd",
			title="asdasd",
			description="asdsad",
			location="asdsad",
			start_date=datetime.datetime.now(),
			end_date=datetime.datetime.now(),
			event_url="http://eee.com",
			contact_person="<EMAIL>",
			country="SI",
			pub_date=datetime.datetime.now())

	def test_get_approved_events(self):
		test_event = Event.objects.get(title="asdasd")
		self.assertEqual("PENDING", test_event.status)
		test_event.status = "APPROVED"
		test_event.save()
		self.assertEqual("APPROVED", test_event.status)

	def test_get_pending_events(self):
		events = get_pending_events()
		self.assertEqual(1, len(events))
{'fraction_non_alphanumeric': 0.13012895662368112, 'fraction_numerical': 0.0017584994138335288, 'mean_word_length': 5.910931174089069, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2323164', 'n_tokens_mistral': 620, 'n_tokens_neox': 557, 'n_words': 92}