2020-05-06 11:32:04 +08:00
|
|
|
|
using NUnit.Framework;
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using System.Threading.Tasks;
|
|
|
|
|
using LeanCloud.Storage;
|
|
|
|
|
|
|
|
|
|
namespace Storage.Test {
|
2021-04-29 15:58:22 +08:00
|
|
|
|
public class SMSTest : BaseTest {
|
2020-05-06 11:32:04 +08:00
|
|
|
|
//[Test]
|
|
|
|
|
public async Task RequestSMS() {
|
2021-04-29 15:58:22 +08:00
|
|
|
|
await LCSMSClient.RequestSMSCode(TestPhone,
|
2020-05-06 11:32:04 +08:00
|
|
|
|
template: "test_template",
|
|
|
|
|
signature: "flutter-test",
|
|
|
|
|
variables: new Dictionary<string, object> {
|
|
|
|
|
{ "k1", "v1" }
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//[Test]
|
|
|
|
|
public async Task RequestVoice() {
|
2021-04-29 15:58:22 +08:00
|
|
|
|
await LCSMSClient.RequestVoiceCode(TestPhone);
|
2020-05-06 11:32:04 +08:00
|
|
|
|
}
|
|
|
|
|
|
2021-04-29 15:58:22 +08:00
|
|
|
|
[Test]
|
2020-05-06 11:32:04 +08:00
|
|
|
|
public async Task Verify() {
|
2021-04-29 15:58:22 +08:00
|
|
|
|
await LCSMSClient.VerifyMobilePhone(TestPhone, TestSMSCode);
|
2020-05-06 11:32:04 +08:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|