importCottonKit@testable importCottonUIimport XCTest/// Days launches on its own colour from the first frame to its first day:/// the splash the app paints after the launch screen is the same flat/// colour (flavour.json `flat`), never the shell's paper (`blank`) it once/// laid, a cream page between the launch screen and today (21 Nov 2026).finalclassDaysSplashTests: XCTestCase {privatefunc manifest(_ flavour: String) throws -> FlavourManifest {try JSONDecoder().decode(FlavourManifest.self, from: Data(trySourceSweep.mustRead("apps/cotton/App/Flavours/\(flavour)/flavour.json", ownedBy: "days").utf8)) }// RULE: a flat app on the shell's paper (Days, Story, Meetings) splashes on its own flat colour; one with a real ground (Keys' leather) keeps it; Notes keeps its theme's, and Cotton its plaster.func testAFlatAppsSplashIsItsOwnColour() throws {let days = try manifest("days") XCTAssertTrue(days.flat, "Days launches flat")for flavour in ["days", "story", "meetings"] {let flat = try manifest(flavour) XCTAssertEqual(SplashGround.of(notes: false, manifest: flat, face: FaceGround.launched(by: flat)), .flat, flavour) }let keys = try manifest("keys")let leather = try XCTUnwrap(FaceGround.launched(by: keys)) XCTAssertEqual(SplashGround.of(notes: false, manifest: keys, face: leather), .face(leather)) XCTAssertEqual(SplashGround.of(notes: true, manifest: try manifest("notes"), face: nil), .notes) XCTAssertEqual(SplashGround.of(notes: false, manifest: nil, face: nil), .plaster) }}#if os(iOS)importSwiftUI/// RULE (launch-ios walk, 22 Nov 2026): the Days · Sometime switch stops growing at the largest size below the accessibility sizes, so at the largest text "Sometime" never runs under the "+".finalclassDaysSwitchSizeTests: XCTestCase {func testTheSwitchIsHeldBelowTheAccessibilitySizes() { XCTAssertFalse(DaysKnobs.switchLargest.isAccessibilitySize) XCTAssertEqual(DaysKnobs.switchLargest, .xxxLarge) }}#endif