def test_get_valid_sheet_name_catches_long_duplicate_names(self): work_sheet_titles = ['childrens_survey_with_a_very_lo'] desired_sheet_name = "childrens_survey_with_a_very_long_name" expected_sheet_name = "childrens_survey_with_a_very_l1" generated_sheet_name = ExportBuilder.get_valid_sheet_name( desired_sheet_name, work_sheet_titles) self.assertEqual(generated_sheet_name, expected_sheet_name)
def test_get_valid_sheet_name_catches_duplicates(self): work_sheets = {'childrens_survey': "Worksheet"} desired_sheet_name = "childrens_survey" expected_sheet_name = "childrens_survey1" generated_sheet_name = ExportBuilder.get_valid_sheet_name( desired_sheet_name, work_sheets) self.assertEqual(generated_sheet_name, expected_sheet_name)
def test_get_valid_sheet_name_catches_long_duplicate_names(self): work_sheet_titles = ['childrens_survey_with_a_very_lo'] desired_sheet_name = "childrens_survey_with_a_very_long_name" expected_sheet_name = "childrens_survey_with_a_very_l1" generated_sheet_name = ExportBuilder.get_valid_sheet_name( desired_sheet_name, work_sheet_titles) self.assertEqual(generated_sheet_name, expected_sheet_name)
def test_get_valid_sheet_name_catches_duplicates(self): work_sheets = {'childrens_survey': "Worksheet"} desired_sheet_name = "childrens_survey" expected_sheet_name = "childrens_survey1" generated_sheet_name = ExportBuilder.get_valid_sheet_name( desired_sheet_name, work_sheets) self.assertEqual(generated_sheet_name, expected_sheet_name)
def test_get_valid_sheet_name_catches_long_names(self): desired_sheet_name = "childrens_survey_with_a_very_long_name" expected_sheet_name = "childrens_survey_with_a_very_lo" generated_sheet_name = ExportBuilder.get_valid_sheet_name( desired_sheet_name, []) self.assertEqual(generated_sheet_name, expected_sheet_name)
def test_get_valid_sheet_name_catches_long_names(self): desired_sheet_name = "childrens_survey_with_a_very_long_name" expected_sheet_name = "childrens_survey_with_a_very_lo" generated_sheet_name = ExportBuilder.get_valid_sheet_name( desired_sheet_name, []) self.assertEqual(generated_sheet_name, expected_sheet_name)