csharp-sdk-upm/Test/Storage.Test/ExceptionTest.cs

18 lines
454 B
C#
Raw Normal View History

2020-02-27 15:30:14 +08:00
using NUnit.Framework;
using LeanCloud.Storage;
2020-03-04 15:17:53 +08:00
using LeanCloud.Common;
2020-02-27 15:30:14 +08:00
namespace LeanCloud.Test {
public class ExceptionTest {
[Test]
public void LeanCloudException() {
try {
throw new LCException(123, "hello, world");
} catch (LCException e) {
TestContext.WriteLine($"{e.Code} : {e.Message}");
Assert.AreEqual(e.Code, 123);
}
}
}
}