add invalid __type check

This commit is contained in:
jim1_lin
2016-02-26 16:39:27 +08:00
committed by Jim Lin
parent bd89338b39
commit d067c0ba61
2 changed files with 34 additions and 17 deletions

View File

@@ -335,6 +335,11 @@ describe('Parse.Object testing', () => {
'Item should not be updated with invalid key.');
item.save({ "foo^bar": "baz" }).then(fail, done);
});
it("invalid __type", function(done) {
var item = new Parse.Object("Item");
item.save({ "foo": {__type: "IvalidName"} }).then(fail, done);
});
it("simple field deletion", function(done) {
var simple = new Parse.Object("SimpleObject");