Example #1
0
 public void RequiresInGroup_should_redirect()
 {
     var mock=new FakeServerContext();
     var auth=new FSCAuth(mock, new FSCAuthConfig(), new SimpleUserStore());
     Prep(auth);
     auth.Login("user", "pass");
     try
     {
         auth.RequiresInGroup("foo");
     }catch(HttpException e)
     {
         Assert.AreEqual(403, e.GetHttpCode());
         return;
     }
     Assert.Fail("Should not reach here. No exception thrown");
 }