Files
ccn/Services/Website/Tests/Library/Cases/Internal/Pages/ErrorPageTests.swift
T
javier 79ecf311f4 Local environment configuration support for the Website service (#19)
This PR contains the work done to amend the `.env.local` handling for the Website service, plus other small fixes.

Reviewed-on: rock-n-code/loud-amsterdam#19
Co-authored-by: Javier Cicchelli <javier@rock-n-code.com>
Co-committed-by: Javier Cicchelli <javier@rock-n-code.com>
2026-07-19 02:28:05 +00:00

29 lines
764 B
Swift

import Elementary
import Foundation
import Testing
@testable import WebsiteLibrary
@Suite("ErrorPage page", .tags(.page))
struct ErrorPageTests {
// MARK: Functional tests
@Test
func `renders its markup`() {
let html = ErrorPage(
locale: .init(identifier: "en")
).render()
#expect(html.contains("<!DOCTYPE html>"))
#expect(html.contains(#"lang="en""#))
#expect(html.contains("Page Not Found"))
#expect(html.contains("Sorry, but the page you were trying to view does not exist."))
#expect(html.contains("/css/shared.css"))
#expect(html.contains("/css/error.css"))
#expect(html.contains("/js/error.js"))
#expect(html.contains("/js/shared.js"))
}
}