     
     func testJsonSerialization()
     {
-        let dictionary = left.asJSON
-        let copy = WordType.fromJSON(dictionary: dictionary)
+        let json = left.asJSON()
+        XCTAssertTrue(json is NSDictionary)
+        let dictionary = json as! NSDictionary
+        
+        let object = WordType.fromJSON(json: dictionary)
+        XCTAssertFalse(object == nil)
+        XCTAssertTrue(object is WordType)
+        
+        let copy = object as! WordType
         XCTAssertTrue(copy == left)
     }
 }

    
    func testDataSerialization()
    {
        let data = left.asData
        let copy = WordType.from(data: data)
        
        XCTAssertTrue(copy == left)

    
    func testAsJSON()
    {
        var json = WordType.Adjective.asJSON()!
        var data = try! JSONSerialization.data(withJSONObject: json, options: [])
        
        json = WordType.Adverb.asJSON
