<s> from datetime import datetime <EOL> from distutils . dist import Distribution <EOL> from distutils . errors import DistutilsOptionError <EOL> from distutils . log import _global_log <EOL> import doctest <EOL> import os <EOL> import shutil <EOL> from StringIO import StringIO <EOL> import sys <EOL> import time <EOL> import unittest <EOL> from babel import __version__ as VERSION <EOL> from babel . dates import format_datetime <EOL> from babel . messages import frontend <EOL> from babel . util import LOCALTZ <EOL> class CompileCatalogTestCase ( unittest . TestCase ) : <EOL> def setUp ( self ) : <EOL> self . olddir = os . getcwd ( ) <EOL> self . datadir = os . path . join ( os . path . dirname ( __file__ ) , '<STR_LIT:data>' ) <EOL> os . chdir ( self . datadir ) <EOL> _global_log . threshold = <NUM_LIT:5> <EOL> self . dist = Distribution ( dict ( <EOL> name = '<STR_LIT>' , <EOL> version = '<STR_LIT>' , <EOL> packages = [ '<STR_LIT>' ] <EOL> ) ) <EOL> self . cmd = frontend . compile_catalog ( self . dist ) <EOL> self . cmd . initialize_options ( ) <EOL> def tearDown ( self ) : <EOL> os . chdir ( self . olddir ) <EOL> def test_no_directory_or_output_file_specified ( self ) : <EOL> self . cmd . locale = '<STR_LIT>' <EOL> self . cmd . input_file = '<STR_LIT>' <EOL> self . assertRaises ( DistutilsOptionError , self . cmd . finalize_options ) <EOL> def test_no_directory_or_input_file_specified ( self ) : <EOL> self . cmd . locale = '<STR_LIT>' <EOL> self . cmd . output_file = '<STR_LIT>' <EOL> self . assertRaises ( DistutilsOptionError , self . cmd . finalize_options ) <EOL> class ExtractMessagesTestCase ( unittest . TestCase ) : <EOL> def setUp ( self ) : <EOL> self . olddir = os . getcwd ( ) <EOL> self . datadir = os . path . join ( os . path . dirname ( __file__ ) , '<STR_LIT:data>' ) <EOL> os . chdir ( self . datadir ) <EOL> _global_log . threshold = <NUM_LIT:5> <EOL> self . dist = Distribution ( dict ( <EOL> name = '<STR_LIT>' , <EOL> version = '<STR_LIT>' , <EOL> packages = [ '<STR_LIT>' ] <EOL> ) ) <EOL> self . cmd = frontend . extract_messages ( self . dist ) <EOL> self . cmd . initialize_options ( ) <EOL> def tearDown ( self ) : <EOL> pot_file = os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' ) <EOL> if os . path . isfile ( pot_file ) : <EOL> os . unlink ( pot_file ) <EOL> os . chdir ( self . olddir ) <EOL> def test_neither_default_nor_custom_keywords ( self ) : <EOL> self . cmd . output_file = '<STR_LIT>' <EOL> self . cmd . no_default_keywords = True <EOL> self . assertRaises ( DistutilsOptionError , self . cmd . finalize_options ) <EOL> def test_no_output_file_specified ( self ) : <EOL> self . assertRaises ( DistutilsOptionError , self . cmd . finalize_options ) <EOL> def test_both_sort_output_and_sort_by_file ( self ) : <EOL> self . cmd . output_file = '<STR_LIT>' <EOL> self . cmd . sort_output = True <EOL> self . cmd . sort_by_file = True <EOL> self . assertRaises ( DistutilsOptionError , self . cmd . finalize_options ) <EOL> def test_extraction_with_default_mapping ( self ) : <EOL> self . cmd . copyright_holder = '<STR_LIT>' <EOL> self . cmd . msgid_bugs_address = '<STR_LIT>' <EOL> self . cmd . output_file = '<STR_LIT>' <EOL> self . cmd . add_comments = '<STR_LIT>' <EOL> self . cmd . finalize_options ( ) <EOL> self . cmd . run ( ) <EOL> pot_file = os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' ) <EOL> assert os . path . isfile ( pot_file ) <EOL> self . assertEqual ( <EOL> r"""<STR_LIT>""" % { '<STR_LIT:version>' : VERSION , <EOL> '<STR_LIT>' : time . strftime ( '<STR_LIT>' ) , <EOL> '<STR_LIT:date>' : format_datetime ( datetime . now ( LOCALTZ ) , '<STR_LIT>' , <EOL> tzinfo = LOCALTZ , locale = '<STR_LIT>' ) } , <EOL> open ( pot_file , '<STR_LIT>' ) . read ( ) ) <EOL> def test_extraction_with_mapping_file ( self ) : <EOL> self . cmd . copyright_holder = '<STR_LIT>' <EOL> self . cmd . msgid_bugs_address = '<STR_LIT>' <EOL> self . cmd . mapping_file = '<STR_LIT>' <EOL> self . cmd . output_file = '<STR_LIT>' <EOL> self . cmd . add_comments = '<STR_LIT>' <EOL> self . cmd . finalize_options ( ) <EOL> self . cmd . run ( ) <EOL> pot_file = os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' ) <EOL> assert os . path . isfile ( pot_file ) <EOL> self . assertEqual ( <EOL> r"""<STR_LIT>""" % { '<STR_LIT:version>' : VERSION , <EOL> '<STR_LIT>' : time . strftime ( '<STR_LIT>' ) , <EOL> '<STR_LIT:date>' : format_datetime ( datetime . now ( LOCALTZ ) , '<STR_LIT>' , <EOL> tzinfo = LOCALTZ , locale = '<STR_LIT>' ) } , <EOL> open ( pot_file , '<STR_LIT>' ) . read ( ) ) <EOL> def test_extraction_with_mapping_dict ( self ) : <EOL> self . dist . message_extractors = { <EOL> '<STR_LIT>' : [ <EOL> ( '<STR_LIT>' , '<STR_LIT:ignore>' , None ) , <EOL> ( '<STR_LIT>' , '<STR_LIT>' , None ) , <EOL> ] <EOL> } <EOL> self . cmd . copyright_holder = '<STR_LIT>' <EOL> self . cmd . msgid_bugs_address = '<STR_LIT>' <EOL> self . cmd . output_file = '<STR_LIT>' <EOL> self . cmd . add_comments = '<STR_LIT>' <EOL> self . cmd . finalize_options ( ) <EOL> self . cmd . run ( ) <EOL> pot_file = os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' ) <EOL> assert os . path . isfile ( pot_file ) <EOL> self . assertEqual ( <EOL> r"""<STR_LIT>""" % { '<STR_LIT:version>' : VERSION , <EOL> '<STR_LIT>' : time . strftime ( '<STR_LIT>' ) , <EOL> '<STR_LIT:date>' : format_datetime ( datetime . now ( LOCALTZ ) , '<STR_LIT>' , <EOL> tzinfo = LOCALTZ , locale = '<STR_LIT>' ) } , <EOL> open ( pot_file , '<STR_LIT>' ) . read ( ) ) <EOL> class InitCatalogTestCase ( unittest . TestCase ) : <EOL> def setUp ( self ) : <EOL> self . olddir = os . getcwd ( ) <EOL> self . datadir = os . path . join ( os . path . dirname ( __file__ ) , '<STR_LIT:data>' ) <EOL> os . chdir ( self . datadir ) <EOL> _global_log . threshold = <NUM_LIT:5> <EOL> self . dist = Distribution ( dict ( <EOL> name = '<STR_LIT>' , <EOL> version = '<STR_LIT>' , <EOL> packages = [ '<STR_LIT>' ] <EOL> ) ) <EOL> self . cmd = frontend . init_catalog ( self . dist ) <EOL> self . cmd . initialize_options ( ) <EOL> def tearDown ( self ) : <EOL> for dirname in [ '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' ] : <EOL> locale_dir = os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' , dirname ) <EOL> if os . path . isdir ( locale_dir ) : <EOL> shutil . rmtree ( locale_dir ) <EOL> os . chdir ( self . olddir ) <EOL> def test_no_input_file ( self ) : <EOL> self . cmd . locale = '<STR_LIT>' <EOL> self . cmd . output_file = '<STR_LIT>' <EOL> self . assertRaises ( DistutilsOptionError , self . cmd . finalize_options ) <EOL> def test_no_locale ( self ) : <EOL> self . cmd . input_file = '<STR_LIT>' <EOL> self . cmd . output_file = '<STR_LIT>' <EOL> self . assertRaises ( DistutilsOptionError , self . cmd . finalize_options ) <EOL> def test_with_output_dir ( self ) : <EOL> self . cmd . input_file = '<STR_LIT>' <EOL> self . cmd . locale = '<STR_LIT>' <EOL> self . cmd . output_dir = '<STR_LIT>' <EOL> self . cmd . finalize_options ( ) <EOL> self . cmd . run ( ) <EOL> po_file = os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , '<STR_LIT>' ) <EOL> assert os . path . isfile ( po_file ) <EOL> self . assertEqual ( <EOL> r"""<STR_LIT>""" % { '<STR_LIT:version>' : VERSION , <EOL> '<STR_LIT:date>' : format_datetime ( datetime . now ( LOCALTZ ) , '<STR_LIT>' , <EOL> tzinfo = LOCALTZ , locale = '<STR_LIT>' ) } , <EOL> open ( po_file , '<STR_LIT>' ) . read ( ) ) <EOL> def test_keeps_catalog_non_fuzzy ( self ) : <EOL> self . cmd . input_file = '<STR_LIT>' <EOL> self . cmd . locale = '<STR_LIT>' <EOL> self . cmd . output_dir = '<STR_LIT>' <EOL> self . cmd . finalize_options ( ) <EOL> self . cmd . run ( ) <EOL> po_file = os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , '<STR_LIT>' ) <EOL> assert os . path . isfile ( po_file ) <EOL> self . assertEqual ( <EOL> r"""<STR_LIT>""" % { '<STR_LIT:version>' : VERSION , <EOL> '<STR_LIT:date>' : format_datetime ( datetime . now ( LOCALTZ ) , '<STR_LIT>' , <EOL> tzinfo = LOCALTZ , locale = '<STR_LIT>' ) } , <EOL> open ( po_file , '<STR_LIT>' ) . read ( ) ) <EOL> def test_correct_init_more_than_2_plurals ( self ) : <EOL> self . cmd . input_file = '<STR_LIT>' <EOL> self . cmd . locale = '<STR_LIT>' <EOL> self . cmd . output_dir = '<STR_LIT>' <EOL> self . cmd . finalize_options ( ) <EOL> self . cmd . run ( ) <EOL> po_file = os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , '<STR_LIT>' ) <EOL> assert os . path . isfile ( po_file ) <EOL> self . assertEqual ( <EOL> r"""<STR_LIT>""" % { '<STR_LIT:version>' : VERSION , <EOL> '<STR_LIT:date>' : format_datetime ( datetime . now ( LOCALTZ ) , '<STR_LIT>' , <EOL> tzinfo = LOCALTZ , locale = '<STR_LIT>' ) } , <EOL> open ( po_file , '<STR_LIT>' ) . read ( ) ) <EOL> def test_correct_init_singular_plural_forms ( self ) : <EOL> self . cmd . input_file = '<STR_LIT>' <EOL> self . cmd . locale = '<STR_LIT>' <EOL> self . cmd . output_dir = '<STR_LIT>' <EOL> self . cmd . finalize_options ( ) <EOL> self . cmd . run ( ) <EOL> po_file = os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , '<STR_LIT>' ) <EOL> assert os . path . isfile ( po_file ) <EOL> self . assertEqual ( <EOL> r"""<STR_LIT>""" % { '<STR_LIT:version>' : VERSION , <EOL> '<STR_LIT:date>' : format_datetime ( datetime . now ( LOCALTZ ) , '<STR_LIT>' , <EOL> tzinfo = LOCALTZ , locale = '<STR_LIT>' ) } , <EOL> open ( po_file , '<STR_LIT>' ) . read ( ) ) <EOL> class CommandLineInterfaceTestCase ( unittest . TestCase ) : <EOL> def setUp ( self ) : <EOL> self . datadir = os . path . join ( os . path . dirname ( __file__ ) , '<STR_LIT:data>' ) <EOL> self . orig_argv = sys . argv <EOL> self . orig_stdout = sys . stdout <EOL> self . orig_stderr = sys . stderr <EOL> sys . argv = [ '<STR_LIT>' ] <EOL> sys . stdout = StringIO ( ) <EOL> sys . stderr = StringIO ( ) <EOL> self . cli = frontend . CommandLineInterface ( ) <EOL> def tearDown ( self ) : <EOL> sys . argv = self . orig_argv <EOL> sys . stdout = self . orig_stdout <EOL> sys . stderr = self . orig_stderr <EOL> for dirname in [ '<STR_LIT>' , '<STR_LIT>' ] : <EOL> locale_dir = os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' , dirname ) <EOL> if os . path . isdir ( locale_dir ) : <EOL> shutil . rmtree ( locale_dir ) <EOL> def test_usage ( self ) : <EOL> try : <EOL> self . cli . run ( sys . argv ) <EOL> self . fail ( '<STR_LIT>' ) <EOL> except SystemExit , e : <EOL> self . assertEqual ( <NUM_LIT:2> , e . code ) <EOL> self . assertEqual ( """<STR_LIT>""" , sys . stderr . getvalue ( ) . lower ( ) ) <EOL> def test_help ( self ) : <EOL> try : <EOL> self . cli . run ( sys . argv + [ '<STR_LIT>' ] ) <EOL> self . fail ( '<STR_LIT>' ) <EOL> except SystemExit , e : <EOL> self . assertEqual ( <NUM_LIT:0> , e . code ) <EOL> self . assertEqual ( """<STR_LIT>""" , sys . stdout . getvalue ( ) . lower ( ) ) <EOL> def test_extract_with_default_mapping ( self ) : <EOL> pot_file = os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' ) <EOL> try : <EOL> self . cli . run ( sys . argv + [ '<STR_LIT>' , <EOL> '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT:-c>' , '<STR_LIT>' , '<STR_LIT:-c>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , pot_file , os . path . join ( self . datadir , '<STR_LIT>' ) ] ) <EOL> except SystemExit , e : <EOL> self . assertEqual ( <NUM_LIT:0> , e . code ) <EOL> assert os . path . isfile ( pot_file ) <EOL> self . assertEqual ( <EOL> r"""<STR_LIT>""" % { '<STR_LIT:version>' : VERSION , <EOL> '<STR_LIT>' : time . strftime ( '<STR_LIT>' ) , <EOL> '<STR_LIT:date>' : format_datetime ( datetime . now ( LOCALTZ ) , '<STR_LIT>' , <EOL> tzinfo = LOCALTZ , locale = '<STR_LIT>' ) } , <EOL> open ( pot_file , '<STR_LIT>' ) . read ( ) ) <EOL> def test_extract_with_mapping_file ( self ) : <EOL> pot_file = os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' ) <EOL> try : <EOL> self . cli . run ( sys . argv + [ '<STR_LIT>' , <EOL> '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , os . path . join ( self . datadir , '<STR_LIT>' ) , <EOL> '<STR_LIT:-c>' , '<STR_LIT>' , '<STR_LIT:-c>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , pot_file , os . path . join ( self . datadir , '<STR_LIT>' ) ] ) <EOL> except SystemExit , e : <EOL> self . assertEqual ( <NUM_LIT:0> , e . code ) <EOL> assert os . path . isfile ( pot_file ) <EOL> self . assertEqual ( <EOL> r"""<STR_LIT>""" % { '<STR_LIT:version>' : VERSION , <EOL> '<STR_LIT>' : time . strftime ( '<STR_LIT>' ) , <EOL> '<STR_LIT:date>' : format_datetime ( datetime . now ( LOCALTZ ) , '<STR_LIT>' , <EOL> tzinfo = LOCALTZ , locale = '<STR_LIT>' ) } , <EOL> open ( pot_file , '<STR_LIT>' ) . read ( ) ) <EOL> def test_init_with_output_dir ( self ) : <EOL> po_file = os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , '<STR_LIT>' ) <EOL> try : <EOL> self . cli . run ( sys . argv + [ '<STR_LIT>' , <EOL> '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' ) , <EOL> '<STR_LIT>' , os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' ) ] ) <EOL> except SystemExit , e : <EOL> self . assertEqual ( <NUM_LIT:0> , e . code ) <EOL> assert os . path . isfile ( po_file ) <EOL> self . assertEqual ( <EOL> r"""<STR_LIT>""" % { '<STR_LIT:version>' : VERSION , <EOL> '<STR_LIT:date>' : format_datetime ( datetime . now ( LOCALTZ ) , '<STR_LIT>' , <EOL> tzinfo = LOCALTZ , locale = '<STR_LIT>' ) } , <EOL> open ( po_file , '<STR_LIT>' ) . read ( ) ) <EOL> def test_init_singular_plural_forms ( self ) : <EOL> po_file = os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , '<STR_LIT>' ) <EOL> try : <EOL> self . cli . run ( sys . argv + [ '<STR_LIT>' , <EOL> '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' ) , <EOL> '<STR_LIT>' , os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' ) ] ) <EOL> except SystemExit , e : <EOL> self . assertEqual ( <NUM_LIT:0> , e . code ) <EOL> assert os . path . isfile ( po_file ) <EOL> self . assertEqual ( <EOL> r"""<STR_LIT>""" % { '<STR_LIT:version>' : VERSION , <EOL> '<STR_LIT:date>' : format_datetime ( datetime . now ( LOCALTZ ) , '<STR_LIT>' , <EOL> tzinfo = LOCALTZ , locale = '<STR_LIT>' ) } , <EOL> open ( po_file , '<STR_LIT>' ) . read ( ) ) <EOL> def test_init_more_than_2_plural_forms ( self ) : <EOL> po_file = os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , '<STR_LIT>' ) <EOL> try : <EOL> self . cli . run ( sys . argv + [ '<STR_LIT>' , <EOL> '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' ) , <EOL> '<STR_LIT>' , os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' ) ] ) <EOL> except SystemExit , e : <EOL> self . assertEqual ( <NUM_LIT:0> , e . code ) <EOL> assert os . path . isfile ( po_file ) <EOL> self . assertEqual ( <EOL> r"""<STR_LIT>""" % { '<STR_LIT:version>' : VERSION , <EOL> '<STR_LIT:date>' : format_datetime ( datetime . now ( LOCALTZ ) , '<STR_LIT>' , <EOL> tzinfo = LOCALTZ , locale = '<STR_LIT>' ) } , <EOL> open ( po_file , '<STR_LIT>' ) . read ( ) ) <EOL> def test_compile_catalog ( self ) : <EOL> po_file = os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , '<STR_LIT>' ) <EOL> mo_file = po_file . replace ( '<STR_LIT>' , '<STR_LIT>' ) <EOL> self . cli . run ( sys . argv + [ '<STR_LIT>' , <EOL> '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' ) ] ) <EOL> assert not os . path . isfile ( mo_file ) , '<STR_LIT>' % mo_file <EOL> self . assertEqual ( """<STR_LIT>""" % ( po_file ) , sys . stderr . getvalue ( ) ) <EOL> def test_compile_fuzzy_catalog ( self ) : <EOL> po_file = os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , '<STR_LIT>' ) <EOL> mo_file = po_file . replace ( '<STR_LIT>' , '<STR_LIT>' ) <EOL> try : <EOL> self . cli . run ( sys . argv + [ '<STR_LIT>' , <EOL> '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' ) ] ) <EOL> assert os . path . isfile ( mo_file ) <EOL> self . assertEqual ( """<STR_LIT>""" % ( po_file , mo_file ) , sys . stderr . getvalue ( ) ) <EOL> finally : <EOL> if os . path . isfile ( mo_file ) : <EOL> os . unlink ( mo_file ) <EOL> def test_compile_catalog_with_more_than_2_plural_forms ( self ) : <EOL> po_file = os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , '<STR_LIT>' ) <EOL> mo_file = po_file . replace ( '<STR_LIT>' , '<STR_LIT>' ) <EOL> try : <EOL> self . cli . run ( sys . argv + [ '<STR_LIT>' , <EOL> '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , os . path . join ( self . datadir , '<STR_LIT>' , '<STR_LIT>' ) ] ) <EOL> assert os . path . isfile ( mo_file ) <EOL> self . assertEqual ( """<STR_LIT>""" % ( po_file , mo_file ) , sys . stderr . getvalue ( ) ) <EOL> finally : <EOL> if os . path . isfile ( mo_file ) : <EOL> os . unlink ( mo_file ) <EOL> def suite ( ) : <EOL> suite = unittest . TestSuite ( ) <EOL> suite . addTest ( doctest . DocTestSuite ( frontend ) ) <EOL> suite . addTest ( unittest . makeSuite ( CompileCatalogTestCase ) ) <EOL> suite . addTest ( unittest . makeSuite ( ExtractMessagesTestCase ) ) <EOL> suite . addTest ( unittest . makeSuite ( InitCatalogTestCase ) ) <EOL> suite . addTest ( unittest . makeSuite ( CommandLineInterfaceTestCase ) ) <EOL> return suite <EOL> if __name__ == '<STR_LIT:__main__>' : <EOL> unittest . main ( defaultTest = '<STR_LIT>' ) </s>
