@@ -73,26 +73,42 @@ def test_component_subset_to_sublist(self):
7373 self .assertEqual (expected , result )
7474
7575 def test_genattrib_basic (self ):
76- self .maxDiff = None
76+ self .maxDiff = None
7777 about_dir = 'about_code_tool/tests/testdata/genattrib/basic/'
7878 generated_attrib = get_temp_file ('generated.html' )
7979 args = [about_dir , generated_attrib ]
8080 options = None
8181 genattrib_command_tester (args , options )
82- expected = open ('about_code_tool/tests/testdata/genattrib/basic.html' ).read ()
8382 result = open (generated_attrib ).read ()
84- self .assertEqual (expected , result )
83+ expected = [
84+ 'ElasticSearch 1.6.0' ,
85+ 'bootstrap 2.3.2' ,
86+ 'djangosnippets.org_2413 2011-04-12' ,
87+ 'Annotator 1.2.10' ,
88+ 'component_4' ,
89+ ]
90+ for ex in expected :
91+ self .assertTrue (ex in result )
8592
8693 def test_genattrib_from_zipped_dir (self ):
87- self .maxDiff = None
94+ self .maxDiff = None
8895 about_dir = 'about_code_tool/tests/testdata/genattrib/zipped_about.zip'
8996 generated_attrib = get_temp_file ('generated.html' )
9097 args = [about_dir , generated_attrib ]
9198 options = None
9299 genattrib_command_tester (args , options )
93- expected = open ('about_code_tool/tests/testdata/genattrib/zipped_about.html' ).read ()
94100 result = open (generated_attrib ).read ()
95- self .assertEqual (expected , result )
101+ expected = [
102+ 'ElasticSearch 1.6.0' ,
103+ 'bootstrap 2.3.2' ,
104+ 'djangosnippets.org_2413 2011-04-12' ,
105+ 'Annotator 1.2.10' ,
106+ 'python-memcached 1.53' ,
107+ 'component_94' ,
108+ 'Groovy 2.4.0' ,
109+ ]
110+ for ex in expected :
111+ self .assertTrue (ex in result )
96112
97113
98114def genattrib_command_tester (args , options ):
0 commit comments