Skip to content

Commit

Permalink
nest in another dictionary to trigger encoding case
Browse files Browse the repository at this point in the history
  • Loading branch information
hborawski committed Sep 27, 2024
1 parent fa05b8a commit 56bcb1c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ios/core/Tests/Types/Generic/AnyTypeTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ class AnyTypeTests: XCTestCase {
XCTAssertEqual("[1,2]", doEncode(AnyType.numberArray(data: [1, 2])))
XCTAssertEqual("[false,true]", doEncode(AnyType.booleanArray(data: [false, true])))
XCTAssertEqual("{\"a\":false,\"b\":1}", doEncode(AnyType.anyDictionary(data: ["a": false, "b": 1])))
XCTAssertEqual("{\"key\":[{\"nestedKey\":\"nestedValue\"}],\"key2\":1}", doEncode(AnyType.anyDictionary(data: ["key2": 1, "key": AnyType.anyArray(data: [["nestedKey": "nestedValue"]])])))
XCTAssertEqual("{\"container\":{\"key\":[{\"nestedKey\":\"nestedValue\"}],\"key2\":1}}", doEncode(AnyType.anyDictionary(data: ["container": AnyType.anyDictionary(data: ["key2": 1, "key": AnyType.anyArray(data: [["nestedKey": "nestedValue"]])])])))
}

func doEncode(_ data: AnyType) -> String? {
Expand Down

0 comments on commit 56bcb1c

Please sign in to comment.