Skip to content

Commit 4ab528a

Browse files
committed
Adds debugging output
1 parent 78b5854 commit 4ab528a

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

Tests/ApolloPaginationTests/ForwardPaginationTests.swift

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -204,6 +204,15 @@ final class ForwardPaginationTests: XCTestCase, CacheDependentTesting {
204204
let newResult = try await XCTUnwrapping(await pager.currentValue)
205205
try XCTAssertSuccessResult(newResult) { output in
206206
// Assert first page is unchanged
207+
if
208+
let oldResults = try? result.get().initialPage,
209+
let newResults = try? newResult.get().initialPage,
210+
oldResults != newResults
211+
{
212+
print("test_fetchMultiplePages_mutateHero - debugging output")
213+
print("Old: \(oldResults.asJSONDictionary())")
214+
print("New: \(newResults.asJSONDictionary())")
215+
}
207216
XCTAssertEqual(try? result.get().initialPage, try? newResult.get().initialPage)
208217
XCTAssertFalse(output.nextPages.isEmpty)
209218
XCTAssertEqual(output.nextPages.count, 1)

0 commit comments

Comments
 (0)