def test_large_name(self): username = trim_to_valid_length( 'thisisaverylongnamethatisinfacttoolong', '.itsi') self.assertEqual(len(username), 30)
def test_large_name(self): username = trim_to_valid_length( 'thisisaverylongnamethatisinfacttoolong', '.itsi') self.assertEqual(len(username), 30)
def test_small_name(self): username = trim_to_valid_length('shortname', '.itsi') self.assertLessEqual(len(username), 30) self.assertEqual( username, 'shortname.itsi', 'The short name should ' + 'be concatenated but otherwise unmodified')
def test_small_name(self): username = trim_to_valid_length('shortname', '.itsi') self.assertLessEqual(len(username), 30) self.assertEqual(username, 'shortname.itsi', 'The short name should ' + 'be concatenated but otherwise unmodified')