'Scenario: Ensure that validation of the content group works correctly.
Given I have a course without content groups
And I create new content group without specifying a name click the button \'Create\'
Then I see error message "Content Group name is required."
When I set a name and click the button \'Create\'
Then I see the content group is saved successfully'

def test_must_supply_name(self):

    self.group_configurations_page.visit()
    self.group_configurations_page.create_first_content_group()
    config = self.group_configurations_page.content_groups[0]
    config.save()
    self.assertEqual(config.mode, u'edit')
    self.assertEqual(u'Group    name    is    required', config.validation_message)
    config.name = u'Content    Group    Name'
    config.save()
    self.assertIn(u'Content    Group    Name', config.name)
