{"size": 808, "ext": "js", "max_stars_repo_path": "src/Umbraco.Tests.AcceptanceTest/cypress/integration/Members/memberGroups.js", "max_stars_repo_name": "jimlofgren/Umbraco-CMS", "max_stars_repo_stars_event_min_datetime": "2021-02-04T23:10:11.000Z", "max_stars_repo_stars_event_max_datetime": "2022-01-30T01:40:20.000Z", "max_issues_repo_path": "src/Umbraco.Tests.AcceptanceTest/cypress/integration/Members/memberGroups.js", "max_issues_repo_name": "jimlofgren/Umbraco-CMS", "max_issues_repo_issues_event_min_datetime": "2021-07-28T08:24:22.000Z", "max_issues_repo_issues_event_max_datetime": "2022-03-25T21:37:30.000Z", "max_forks_repo_path": "src/Umbraco.Tests.AcceptanceTest/cypress/integration/Members/memberGroups.js", "max_forks_repo_name": "jimlofgren/Umbraco-CMS", "max_forks_repo_forks_event_min_datetime": "2021-03-26T16:50:47.000Z", "max_forks_repo_forks_event_max_datetime": "2022-03-24T18:32:06.000Z"}
{"max_stars_count": 2, "max_issues_count": 197, "max_forks_count": 14, "avg_line_length": 24.4848484848, "max_line_length": 77, "alphanum_fraction": 0.5878712871}
context('User Groups', () => {

    beforeEach(() => {
        cy.umbracoLogin(Cypress.env('username'), Cypress.env('password'));
    });

    it('Create member group', () => {
        const name = "Test Group";

        cy.umbracoEnsureMemberGroupNameNotExists(name);

        cy.umbracoSection('member');
        cy.get('li .umb-tree-root:contains("Members")').should("be.visible");

        cy.umbracoTreeItem("member", ["Member Groups"]).rightclick();

        cy.umbracoContextMenuAction("action-create").click();

        //Type name
        cy.umbracoEditorHeaderName(name);

        // Save
        cy.get('.btn-success').click();

        //Assert
        cy.umbracoSuccessNotification().should('be.visible');

        //Clean up
        cy.umbracoEnsureMemberGroupNameNotExists(name);
    });

});
