This commit is contained in:
2018-12-18 16:33:35 +00:00
parent 077ee889eb
commit 27b77c5273
36 changed files with 10640 additions and 0 deletions

36
Authentication/Auth.cs Normal file
View File

@@ -0,0 +1,36 @@
using System;
using Xunit;
using Newtonsoft.Json.Linq;
using FluentAssertions;
namespace raven_integration
{
public class Auth
{
/// <summary>
///
/// </summary>
[Fact]
public async void BadLoginShouldNotWork()
{
//Expect status code 401 and result:
// {{
// "error": {
// "code": "2003",
// "message": "Authentication failed"
// }
// }}
dynamic d = new JObject();
d.login = "BOGUS";
d.password = "ACCOUNT";
ApiResponse a = await Util.PostAsync("Auth", null, d.ToString());
Util.ValidateErrorCodeResponse(a,2003,401);
}
//==================================================
}//eoc
}//eons