// // MonthViewInteractionTests.swift // Tests iOS // // Month view interaction tests -- tapping and scrolling content. // import XCTest final class MonthViewInteractionTests: BaseUITestCase { override var seedFixture: String? { "week_of_moods" } /// TC-030: Tap on month grid and verify the app remains stable. func testMonthView_TapContent_NoCrash() { let tabBar = TabBarScreen(app: app) tabBar.tapMonth() let monthGrid = app.element(UITestID.Month.grid) monthGrid.waitUntilHittableOrFail( timeout: navigationTimeout, message: "Month grid should be hittable" ) monthGrid.forceTap() // Verify the tab bar is still present (app did not crash) tabBar.assertVisible() captureScreenshot(name: "month_view_after_tap") } /// Navigate to Month tab with data, scroll down/up, and verify no crash. func testMonthView_Scroll_NoCrash() { let tabBar = TabBarScreen(app: app) tabBar.tapMonth() let monthGrid = app.element(UITestID.Month.grid) monthGrid.waitForExistenceOrFail( timeout: navigationTimeout, message: "Month grid should be visible for scrolling" ) app.swipeUp() app.swipeDown() tabBar.assertVisible() captureScreenshot(name: "month_view_after_scroll") } }