<s> import logging <EOL> import unittest <EOL> from mock import patch <EOL> from kuyruk import Task <EOL> from tests import tasks <EOL> logger = logging . getLogger ( __name__ ) <EOL> class KuyrukTestCase ( unittest . TestCase ) : <EOL> def test_task_decorator ( self ) : <EOL> """<STR_LIT>""" <EOL> self . assertTrue ( isinstance ( tasks . echo , Task ) ) <EOL> self . assertTrue ( isinstance ( tasks . echo_another , Task ) ) <EOL> @ patch ( '<STR_LIT>' ) <EOL> def test_eager ( self , mock_func ) : <EOL> """<STR_LIT>""" <EOL> tasks . eager_task ( ) <EOL> mock_func . assert_called_once_with ( ) <EOL> @ patch ( '<STR_LIT>' ) <EOL> def test_apply ( self , mock_func ) : <EOL> """<STR_LIT>""" <EOL> tasks . echo . apply ( "<STR_LIT:hello>" ) <EOL> mock_func . assert_called_once_with ( ) <EOL> def test_task_name ( self ) : <EOL> self . assertEqual ( tasks . echo . name , '<STR_LIT>' ) </s>
