'Tests the expected display name for the duplicated xblock.'

def test_display_name(self):

    def verify_name(source_usage_key, parent_usage_key, expected_name, display_name=None):
        usage_key = self._duplicate_item(parent_usage_key, source_usage_key, display_name)
        duplicated_item = self.get_item_from_modulestore(usage_key)
        self.assertEqual(duplicated_item.display_name, expected_name)
        return usage_key
    dupe_usage_key = verify_name(self.problem_usage_key, self.vert_usage_key, "Duplicate    of    'Multiple    Choice'")
    verify_name(dupe_usage_key, self.vert_usage_key, "Duplicate    of    'Duplicate    of    'Multiple    Choice''")
    verify_name(self.html_usage_key, self.vert_usage_key, "Duplicate    of    'Text'")
    verify_name(self.seq_usage_key, self.chapter_usage_key, 'Duplicate    of    sequential')
    verify_name(self.seq_usage_key, self.chapter_usage_key, 'customized    name', display_name='customized    name')
