oneRain 2021-04-30 16:29:51 +08:00
parent 7278f34977
commit 76692cff44
4 changed files with 9 additions and 9 deletions

View File

@ -18,7 +18,6 @@ namespace Storage.Test {
PublicWriteAccess = false
};
account.Balance = 1024;
account["balance"] = 1024;
await account.Save();
Assert.IsFalse(account.ACL.PublicReadAccess);
Assert.IsFalse(account.ACL.PublicWriteAccess);

View File

@ -57,8 +57,8 @@ namespace Storage.Test {
LCLogger.LogDelegate += Print;
LCApplication.Initialize(AppId, AppKey, AppServer);
LCObject.RegisterSubclass("Account", () => new Account());
LCObject.RegisterSubclass<Hello>("Hello", () => new Hello());
LCObject.RegisterSubclass<World>("World", () => new World());
LCObject.RegisterSubclass("Hello", () => new Hello());
LCObject.RegisterSubclass("World", () => new World());
}
[TearDown]

View File

@ -23,9 +23,9 @@ namespace Storage.Test {
{ "k2", true },
{ "k3", "haha" }
};
LCObject nestedObj = new LCObject("World");
nestedObj["content"] = "7788";
@object["objectValue"] = nestedObj;
World nestedObj = new World();
nestedObj.Content = "7788";
@object.World = nestedObj;
@object["pointerList"] = new List<object> { new LCObject("World"), nestedObj };
await @object.Save();

View File

@ -157,9 +157,10 @@ namespace Storage.Test {
[Test]
[Order(10)]
public async Task UpdatePassword() {
LCUser currentUser = await LCUser.Login("hello", "world");
await currentUser.UpdatePassword("world", "newWorld");
await currentUser.UpdatePassword("newWorld", "world");
LCUser currentUser = await LCUser.Login(TestPhone, TestPhone);
string newPassword = "newpassword";
await currentUser.UpdatePassword(TestPhone, newPassword);
await currentUser.UpdatePassword(newPassword, TestPhone);
}
[Test]