Skip to content

Commit

Permalink
DDCNL-9316 - Fixed failed test case
Browse files Browse the repository at this point in the history
  • Loading branch information
jmsatheesh committed Aug 19, 2024
1 parent 716ae8c commit 4a580b5
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 8 deletions.
3 changes: 1 addition & 2 deletions app/views/templates/page_not_found_template.scala.html
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,7 @@

@()(implicit messages: Messages, request: Request[_])

@main(pageTitle = messages("title.pattern", messages("global.page.not.found.error.title"))){

@main(pageTitle = messages("global.page.not.found.error.title")){
@h1("global.page.not.found.error.title")

@p(Text(messages("global.page.not.found.error.check.web.address.correct")))
Expand Down
5 changes: 2 additions & 3 deletions project/LibraryDependencies.scala
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,9 @@ import sbt.*

object LibraryDependencies {

private val hmrcScaWrapperVersion = "1.11.0"
private val hmrcScaWrapperVersion = "1.11.0"
private val hmrcMongoVersion = "2.1.0"

private val playVersion = "play-30"
private val playVersion = "play-30"

private val compile: Seq[ModuleID] = Seq(
"uk.gov.hmrc" %% s"sca-wrapper-$playVersion" % hmrcScaWrapperVersion,
Expand Down
6 changes: 3 additions & 3 deletions test/errorHandler/ErrorHandlerSpec.scala
Original file line number Diff line number Diff line change
Expand Up @@ -50,11 +50,11 @@ class ErrorHandlerSpec extends UnitSpec with GuiceOneAppPerSuite with Injecting{
val standardErrorTemplate: Html = errorHandler.standardErrorTemplate(title, heading, message)
val doc: Document = Jsoup.parse(standardErrorTemplate.toString())

val docTitle = doc.select("title").text()
val docTitle = doc.title()
val docHeading = doc.select("#errorHeading").text()
val docMessage = doc.select("#errorText").text()

docTitle shouldBe s"$title - Marriage Allowance - GOV.UK GOV.UK"
docTitle shouldBe title + " - " + messages("title.pattern")
docHeading shouldBe heading
docMessage shouldBe message
}
Expand All @@ -65,7 +65,7 @@ class ErrorHandlerSpec extends UnitSpec with GuiceOneAppPerSuite with Injecting{
val notFoundTemplate: Html = errorHandler.notFoundTemplate
val doc: Document = Jsoup.parse(notFoundTemplate.toString())

val docTitle = doc.select("title").text()
val docTitle = doc.title()
docTitle should include(messages("title.pattern"))
}
}
Expand Down

0 comments on commit 4a580b5

Please sign in to comment.