# Path: errors.py
# class TaintedLove(Exception):
# 
#     def __init__(self, user_message, is_error=True):
#         self.user_message = user_message
#         self.is_error = (is_error is True)
# 
# Path: testing/factories/alias.py
# def create_alias_with_employee_username(
#     name='jda',
#     username='jd',
# ):
#     alias = Alias(
#         name=name,
#         owner_key=Employee.get_key_for_username(username),
#     )
#     alias.put()
#     return alias
# 
# Path: testing/factories/employee.py
# def create_employee(
#     username='johndoe',
#     department='Engineering',
#     first_name='John',
#     last_name='Doe',
#     photo_url=None,
#     office=None,
# ):
# 
#     if photo_url is None:
#         photo_url = 'http://example.com/photos/{0}.jpg'.format(username)
# 
#     return Employee.create_from_dict({
#         'username': username,
#         'department': department,
#         'first_name': first_name,
#         'last_name': last_name,
#         'photo_url': photo_url,
#         'office': office,
#     })


import mock
import unittest
import logic.love
from config import CompanyValue
from errors import TaintedLove
from testing.factories import create_alias_with_employee_username
from testing.factories import create_employee
# -*- coding: utf-8 -*-



class SendLovesTest(unittest.TestCase):
    nosegae_taskqueue = True
    nosegae_memcache = True
    nosegae_datastore_v3 = True

    def setUp(self):
        self.alice = create_employee(username='alice')

# Path: errors.py
# class TaintedLove(Exception):
# 
#     def __init__(self, user_message, is_error=True):
#         self.user_message = user_message
#         self.is_error = (is_error is True)
# 
# Path: testing/factories/alias.py
# def create_alias_with_employee_username(
#     name='jda',
#     username='jd',
# ):
#     alias = Alias(
#         name=name,
#         owner_key=Employee.get_key_for_username(username),
#     )
#     alias.put()
#     return alias
# 
# Path: testing/factories/employee.py
# def create_employee(
#     username='johndoe',
#     department='Engineering',
#     first_name='John',
#     last_name='Doe',
#     photo_url=None,
#     office=None,
# ):
# 
#     if photo_url is None:
#         photo_url = 'http://example.com/photos/{0}.jpg'.format(username)
# 
#     return Employee.create_from_dict({
#         'username': username,
#         'department': department,
#         'first_name': first_name,
#         'last_name': last_name,
#         'photo_url': photo_url,
#         'office': office,
#     })


# Path: tests/logic/love_test.py
import mock
import unittest
import logic.love
from config import CompanyValue
from errors import TaintedLove
from testing.factories import create_alias_with_employee_username
from testing.factories import create_employee

# -*- coding: utf-8 -*-



class SendLovesTest(unittest.TestCase):
    nosegae_taskqueue = True
    nosegae_memcache = True
    nosegae_datastore_v3 = True

    def setUp(self):
        self.alice = create_employee(username='alice')

        self.bob = create_employee(username='bob')