Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit b9e29d5

Browse files
committed
Fix test failure
1 parent 8bb7468 commit b9e29d5

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

shell/platform/darwin/ios/framework/Source/FlutterRestorationPluginTest.mm

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -54,15 +54,14 @@ - (void)testRestoratonViewControllerEncodeAndDecode {
5454
NSKeyedArchiver* archiver = [[NSKeyedArchiver alloc] initRequiringSecureCoding:YES];
5555
[flutterViewController encodeRestorableStateWithCoder:archiver];
5656

57-
XCTAssertEqual([restorationPlugin restorationData], archiver.encodedData);
58-
5957
[restorationPlugin setRestorationData:nil];
6058

6159
NSKeyedUnarchiver* unarchiver =
6260
[[NSKeyedUnarchiver alloc] initForReadingWithData:archiver.encodedData];
6361
[flutterViewController decodeRestorableStateWithCoder:unarchiver];
6462

65-
XCTAssertEqual([restorationPlugin restorationData], archiver.encodedData);
63+
XCTAssert([[restorationPlugin restorationData] isEqualToData:data],
64+
"Restoration state data must be equal");
6665
}
6766

6867
- (void)testRestorationEnabledWaitsForData {

0 commit comments

Comments
 (0)