public void Test_InsertAccess()
        {
            //this method would test the insertion of access items into the database
            var store = new Store();
            //setup the data
            List<Access>listAcess = new List<Access>()
            {
                new Access(){level = 1,description = "client level access", title = "Client"},
                new Access(){level = 2,description = "advocate level access",title = "Advocate"},
                new Access(){level = 3,description = "admin level access",title = "Admin"},
                new Access(){level = 4,description = "developer level access",title = "Developer"}
            };

            //fire the test
            var task =  store.InsertAccess(listAcess);
            task.Wait();

            //check if the store has the the new access ..
        }
        public void Test_GetAccess_ByLevel()
        {
            //testing for the level that is present in the database
            var store = new Store();
            var task = store.GetAccess(2);
            task.Wait();
            Trace.WriteLine(String.Format("We have received the access from the database {0}, {1}, {2}", task.Result.level, task.Result.description, task.Result.title));
            Assert.IsNotNull(task.Result, "Not received the level from the database");
            Assert.IsTrue(task.Result.level==2, "Incorrect access by the level");

            //testing for an invalid level
            task = store.GetAccess(-1);
            task.Wait();
            Assert.IsNull(task.Result, "Unexpected not null result from te database");

            task = store.GetAccess(6);
            task.Wait();
            Assert.IsNull(task.Result, "Unexpected not null result from the database");
        }
 public void InitTest()
 {
     this.Store = new Store();
 }