<commit_before>const expect = require('chai').expect
const authenticationHelp = require('../helpers/routes/authentication-helper')

describe('View internal server error page', () => {
  before(async function () {
    await authenticationHelp.login(authenticationHelp.users.SystemAdmin)
  })

  describe('should navigate to the internal server error page', () => {
    it('with the correct heading title', async () => {
      await browser.url('/probation/region/999')

      const pageTitle = await $('.govuk-heading-xl')
      const text = await pageTitle.getText('.govuk-heading-xl')
      expect(text).to.equal('An error has occurred')
    })
  })

  after(function () {
    authenticationHelp.logout()
  })
})
<commit_msg>WFP-458 fixed assertion to correct title content<commit_after>const expect = require('chai').expect
const authenticationHelp = require('../helpers/routes/authentication-helper')

describe('View internal server error page', () => {
  before(async function () {
    await authenticationHelp.login(authenticationHelp.users.SystemAdmin)
  })

  describe('should navigate to the internal server error page', () => {
    it('with the correct heading title', async () => {
      await browser.url('/probation/region/999')

      const pageTitle = await $('.govuk-heading-xl')
      const text = await pageTitle.getText('.govuk-heading-xl')
      expect(text).to.equal('Sorry, there is a problem with the service')
    })
  })

  after(function () {
    authenticationHelp.logout()
  })
})

{'fraction_non_alphanumeric': 0.14323607427055704, 'fraction_numerical': 0.005968169761273209, 'mean_word_length': 3.9313725490196076, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 9, 'https://': 0, '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': '5087159', 'n_tokens_mistral': 420, 'n_tokens_neox': 412, 'n_words': 100}