4648
This commit is contained in:
@@ -28,7 +28,7 @@ namespace raven_integration
|
||||
[Fact]
|
||||
public async Task ServerShouldNotAllowReadUnauthorizedAccess()
|
||||
{
|
||||
ApiResponse a = await Util.GetAsync("widget/listwidgets", await Util.GetTokenAsync( "OpsAdminFull"));
|
||||
ApiResponse a = await Util.GetAsync("widget/listwidgets", await Util.GetTokenAsync( "OpsAdmin"));
|
||||
//2004 unauthorized
|
||||
Util.ValidateErrorCodeResponse(a, 2004, 403);
|
||||
}
|
||||
@@ -49,8 +49,8 @@ namespace raven_integration
|
||||
d.active = true;
|
||||
d.usertype = 1;
|
||||
|
||||
//BizAdminLimited user should not be able to create a widget, only read them
|
||||
ApiResponse a = await Util.PostAsync("widget", await Util.GetTokenAsync( "BizAdminLimited"), d.ToString());
|
||||
//BizAdminRestricted user should not be able to create a widget, only read them
|
||||
ApiResponse a = await Util.PostAsync("widget", await Util.GetTokenAsync( "BizAdminRestricted"), d.ToString());
|
||||
|
||||
//2004 unauthorized
|
||||
Util.ValidateErrorCodeResponse(a, 2004, 403);
|
||||
|
||||
Reference in New Issue
Block a user