<commit_before>
describe('An actual test on our app', function () {

  it("Tests our AGOL app's overwrite of our constructor parameters", function () {

    cy.visit('https://my.gfw-mapbuilder.org/v1.4.0/?appid=277b92455c6c49059a95c9129be7baf9&l=en');

    cy.window().then(windowObject => {
      const app = windowObject.customApp;
      expect(app).to.not.be.an('undefined');

      const constructorParams = app.constructorArgs;
      const config = constructorParams.config;
      cy.wait(2000);

      cy.get('.app-header__title').should(($div) => {
        const titleText = $div.get(0).innerText;
        expect(titleText.toLowerCase()).to.not.eq(config.title.toLowerCase());
      });
      cy.get('.app-header__subtitle').should(($div) => {
        const subtitleText = $div.get(0).innerText;
        expect(subtitleText.toLowerCase()).to.not.eq(config.subtitle.toLowerCase());
      });

      cy.get('.app-header__nav-list').children().should('have.length', 5);

      cy.get('.app-header__logo-container').find('img').should('have.attr', 'src').should('not.include', config.logoUrl);

    });

  });

  it("Tests our site's html for our constructor parameters", function () {

    cy.visit('https://my.gfw-mapbuilder.org/v1.4.0/');

    cy.window().then(windowObject => {
      const app = windowObject.customApp;
      expect(app).to.not.be.an('undefined');

      const constructorParams = app.constructorArgs;
      const config = constructorParams.config;
      cy.wait(2000);

      cy.get('.app-header__title').should(($div) => {
        const titleText = $div.get(0).innerText;
        expect(titleText.toLowerCase()).to.eq(config.title.toLowerCase());
      });
      cy.get('.app-header__subtitle').should(($div) => {
        const subtitleText = $div.get(0).innerText;
        expect(subtitleText.toLowerCase()).to.eq(config.subtitle.toLowerCase());
      });

      cy.get('.app-header__nav-list').children().should('have.length', 1);

      cy.get('.app-header__logo-container').find('img').should('have.attr', 'src').should('include', config.logoUrl);

    });

  });

});<commit_msg>Additional agol tests to match Richard's TestCases<commit_after>
describe('An actual test on our app', function () {

  it("Tests our AGOL app's overwrite of our constructor parameters", function () {

    cy.visit('https://my.gfw-mapbuilder.org/v1.4.0/?appid=277b92455c6c49059a95c9129be7baf9&l=en');

    cy.window().then(windowObject => {
      const app = windowObject.customApp;
      expect(app).to.not.be.an('undefined');

      const constructorParams = app.constructorArgs;
      const config = constructorParams.config;
      cy.wait(2000);

      cy.get('.app-header__title').should(($div) => {
        const titleText = $div.get(0).innerText;
        expect(titleText.toLowerCase()).to.not.eq(config.title.toLowerCase());
      });
      cy.get('.app-header__subtitle').should(($div) => {
        const subtitleText = $div.get(0).innerText;
        expect(subtitleText.toLowerCase()).to.not.eq(config.subtitle.toLowerCase());
      });

      cy.get('.app-header__logo-container').find('img').should('have.attr', 'src').should('not.include', config.logoUrl);
      cy.get('.app-header__logo-container').find('a').should('have.attr', 'href').should('not.include', config.logoLinkUrl);

      cy.get('.app-header__nav-link--map-themes').should('have.length', 1);
      cy.get('.app-header__nav-link--gfw-login').should('have.length', 1);
      cy.get('.app-header__nav-link--language').should('have.length', 1);
      cy.get('.app-header__language-list').children().should('have.length', 2);
      cy.get('.app-header__language').first().should('have.attr', 'data-lang').should('include', 'en');
      cy.get('.app-header__language').last().should('have.attr', 'data-lang').should('include', 'fr');
      cy.get('.app-header__language').first().should('have.class', 'active');
      //.app-header__language.active

      cy.get('[data-value="MEASUREMENT"]').should('have.length', 1);
      cy.get('[data-value="DOCUMENTS"]').should('have.length', 1);
      cy.get('[data-value="NARRATIVE"]').should('have.length', 1);

    });

  });

  it("Tests our site's html for our constructor parameters", function () {

    cy.visit('https://my.gfw-mapbuilder.org/v1.4.0/');

    cy.window().then(windowObject => {
      const app = windowObject.customApp;
      expect(app).to.not.be.an('undefined');

      const constructorParams = app.constructorArgs;
      const config = constructorParams.config;
      cy.wait(2000);

      cy.get('.app-header__title').should(($div) => {
        const titleText = $div.get(0).innerText;
        expect(titleText.toLowerCase()).to.eq(config.title.toLowerCase());
      });
      cy.get('.app-header__subtitle').should(($div) => {
        const subtitleText = $div.get(0).innerText;
        expect(subtitleText.toLowerCase()).to.eq(config.subtitle.toLowerCase());
      });

      cy.get('.app-header__nav-list').children().should('have.length', 1);

      cy.get('.app-header__logo-container').find('img').should('have.attr', 'src').should('include', config.logoUrl);
      cy.get('.app-header__logo-container').find('a').should('have.attr', 'href').should('include', config.logoLinkUrl);

      cy.get('.app-header__nav-link--map-themes').should('have.length', 0);
      cy.get('.app-header__nav-link--gfw-login').should('have.length', 1);
      cy.get('.app-header__nav-link--language').should('have.length', 0);

      if (config.includeMeasurementTab) {
        cy.get('[data-value="MEASUREMENT"]').should('have.length', 1);
      } else {
        cy.get('[data-value="MEASUREMENT"]').should('have.length', 0);
      }

      if (config.includeDocumentsTab) {
        cy.get('[data-value="DOCUMENTS"]').should('have.length', 1);
      } else {
        cy.get('[data-value="DOCUMENTS"]').should('have.length', 0);
      }

      if (config.narrative) {
        cy.get('[data-value="NARRATIVE"]').should('have.length', 1);
      } else {
        cy.get('[data-value="NARRATIVE"]').should('have.length', 0);
      }

    });

  });

});
{'fraction_non_alphanumeric': 0.20453425332676195, 'fraction_numerical': 0.016264169541646133, 'mean_word_length': 3.421205519244735, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 15, 'https://': 4, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4205963', 'n_tokens_mistral': 2030, 'n_tokens_neox': 1946, 'n_words': 226}