# Path: errors.py
# class NoSuchLoveLink(Exception):
#     pass
# 
# Path: testing/factories/love_link.py
# def create_love_link(
#     hash_key='lOvEr',
#     message='I <3 love links',
#     recipient_list='johndoe, janedoe',
# ):
# 
#     new_love_link = LoveLink(
#         hash_key=hash_key,
#         message=message,
#         recipient_list=recipient_list,
#     )
#     new_love_link.put()
# 
#     return new_love_link
# 
# 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 unittest
import datetime
import logic.love
import logic.love_link
from errors import NoSuchLoveLink
from testing.factories import create_love_link
from testing.factories import create_employee
# -*- coding: utf-8 -*-




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

    def setUp(self):
        self.link = create_love_link(hash_key='HeLLo', recipient_list='johndoe,janedoe', message='well hello there')
        self.princessbubblegum = create_employee(username='princessbubblegum')

    def test_get_love_link(self):
        link = logic.love_link.get_love_link('HeLLo')
        self.assertEqual(link.hash_key, 'HeLLo')
        self.assertEqual(link.recipient_list, 'johndoe,janedoe')
        self.assertEqual(link.message, 'well hello there')

    def test_create_love_link(self):

# Path: errors.py
# class NoSuchLoveLink(Exception):
#     pass
# 
# Path: testing/factories/love_link.py
# def create_love_link(
#     hash_key='lOvEr',
#     message='I <3 love links',
#     recipient_list='johndoe, janedoe',
# ):
# 
#     new_love_link = LoveLink(
#         hash_key=hash_key,
#         message=message,
#         recipient_list=recipient_list,
#     )
#     new_love_link.put()
# 
#     return new_love_link
# 
# 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_link_test.py
import unittest
import datetime
import logic.love
import logic.love_link
from errors import NoSuchLoveLink
from testing.factories import create_love_link
from testing.factories import create_employee

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




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

    def setUp(self):
        self.link = create_love_link(hash_key='HeLLo', recipient_list='johndoe,janedoe', message='well hello there')
        self.princessbubblegum = create_employee(username='princessbubblegum')

    def test_get_love_link(self):
        link = logic.love_link.get_love_link('HeLLo')
        self.assertEqual(link.hash_key, 'HeLLo')
        self.assertEqual(link.recipient_list, 'johndoe,janedoe')
        self.assertEqual(link.message, 'well hello there')

    def test_create_love_link(self):

        link = logic.love_link.create_love_link('jake', "it's adventure time!")