15 lines
360 B
Python
15 lines
360 B
Python
import sys
|
|
import os
|
|
sys.path.insert(0, os.path.dirname(__file__))
|
|
|
|
import unittest
|
|
from name_function import get_formatted_name
|
|
|
|
class NameTestCase(unittest.TestCase):
|
|
"""测试"""
|
|
def test_first_last_name(self):
|
|
|
|
formatted_name = get_formatted_name('janis', 'joplin')
|
|
self.assertEqual(formatted_name, 'Janis Joplin')
|
|
|
|
#unittest.main() |