rendered_chapters=world.browser.find_by_css('#accordion > nav > div')
num_rendered_chapters=len(rendered_chapters)
assertnum_chapters==num_rendered_chapters,'%d chapters expected, %d chapters found on page for %s'%(num_chapters,num_rendered_chapters,course_id)
msg='%d chapters expected, %d chapters found on page for %s'%(num_chapters,num_rendered_chapters,course_id)
logger.debug(msg)
assertnum_chapters==num_rendered_chapters,msg
chapter_it=0
...
...
@@ -95,7 +73,10 @@ def browse_course(course_id):
rendered_sections=world.browser.find_by_css('#accordion > nav > div')[chapter_it].find_by_tag('li')
num_rendered_sections=len(rendered_sections)
assertnum_sections==num_rendered_sections,'%d sections expected, %d sections found on page, iteration number %d on %s'%(num_sections,num_rendered_sections,chapter_it,course_id)
msg='%d sections expected, %d sections found on page, %s - %d - %s'%(num_sections,num_rendered_sections,course_id,chapter_it,chapters[chapter_it]['chapter_name'])
logger.debug(msg)
assertnum_sections==num_rendered_sections,msg
section_it=0
...
...
@@ -123,7 +104,9 @@ def browse_course(course_id):
rendered_tabs=0
num_rendered_tabs=0
assertnum_tabs==num_rendered_tabs,'%d tabs expected, %d tabs found, iteration number %d, on %s'%(num_tabs,num_rendered_tabs,section_it,course_id)