public GetOne ( string adminId = null, string adminEmail = null ) : Task |
||
adminId | string | Admin id. |
adminEmail | string | Admin email. |
리턴 | Task |
public async Task GetOne_WithNullAdminIdAndEmail_ThrowsException(AdministratorSyncanoClient client) { try { //when await client.GetOne(); throw new Exception("GetOne should throw an exception"); } catch (Exception e) { //then e.ShouldBeType<ArgumentNullException>(); } }
public async Task GetOne_WithInvalidAdminEmail_ThrowsException(AdministratorSyncanoClient client) { try { //when await client.GetOne(adminEmail: "*****@*****.**"); throw new Exception("GetOne should throw an exception"); } catch (Exception e) { //then e.ShouldBeType<SyncanoException>(); } }
public async Task GetOne_ByAdminEmail_CreatesAdministrator(AdministratorSyncanoClient client) { //when var result = await client.GetOne(adminEmail: TestData.AdminEmail); //then result.ShouldNotBeNull(); result.Id.ShouldEqual(TestData.AdminId); }