         person.adult = true
 
         if let dict = person.toJSONObject() as? JSONDictionary {
-            XCTAssertEqual(dict["name"] as! String, "lancy", "my name is lancy")
-            XCTAssertEqual(dict["age"] as! Int, 23, "I'm 23")
-            XCTAssertEqual(dict["birthday"] as! Double, 14, "my birthday is 14")
-            XCTAssertEqual(dict["weight"] as! Float, 60, "weight 60!")
-            XCTAssertEqual(dict["adult"] as! Bool, true, "i'm an adult")
+            XCTAssertEqual((dict["name"] as! String), "lancy", "my name is lancy")
+            XCTAssertEqual((dict["age"] as! Int), 23, "I'm 23")
+            XCTAssertEqual((dict["birthday"] as! Double), 14, "my birthday is 14")
+            XCTAssertEqual((dict["weight"] as! Float), 60, "weight 60!")
+            XCTAssertEqual((dict["adult"] as! Bool), true, "i'm an adult")
         } else {
             XCTFail("JSON Object should be a dictionary")
         }

        person.girlFriend = girl

        if let dict = person.toJSONObject() as? JSONDictionary {
            XCTAssertEqual(dict["name"] as! String, "lancy", "my name is lancy")
            if let girlDict = dict["girlFriend"] as? JSONDictionary {
                XCTAssertEqual(girlDict["name"] as! String, "grace", "my girl is grace")
            } else {
                XCTFail("JSON Object of girl friend should be a dictionary")
            }

        let person = Person(name: "siri")
        person.orientation = [.Male, .Female, .Unknown]
        if let dict = person.toJSONObject() as? JSONDictionary {
            XCTAssertEqual((dict["name"] as! String), "siri", "my name is siri")
            if let orientation = dict["orientation"] as? [Int] {
                XCTAssertEqual(orientation[0], Sex.Male.rawValue, "siri likes male!")
                XCTAssertEqual(orientation[1], Sex.Female.rawValue, "siri also likes female!")
                XCTAssertEqual(orientation[2], Sex.Unknown.rawValue, "and siri likes all others!")
            } else {
                XCTFail("JSON Object of orientation should be a [Int]")
            }
