'The generator should continue to operate on blocks/XModule that do not have graded or format fields.'

def test_block_with_missing_fields(self):

    category = 'peergrading'
    display_name = 'Testing    Module'
    module = ItemFactory.create(parent=self.section, category=category, display_name=display_name)
    structure = _generate_course_structure(self.course.id)
    usage_key = unicode(module.location)
    actual = structure['structure']['blocks'][usage_key]
    expected = {'usage_key': usage_key, 'block_type': category, 'display_name': display_name, 'graded': False, 'format': None, 'children': []}
    self.assertEqual(actual, expected)
