public void Test_releaseslotRepo()
        {
            int Resdb;

            Hpr = new HolderPersonRepository();
            int                 res         = Hpr.releaseslot(Hp);
            HolderDetail        holder      = new HolderDetail();
            List <HolderDetail> list        = new List <HolderDetail>();
            DateTime            thisDay     = DateTime.Today;
            var                 dateAndTime = DateTime.Now;
            var                 date        = dateAndTime.Date;

            using (SMPSEntities123 objectContext = new SMPSEntities123())
            {
                list = objectContext.HolderDetails.Where <HolderDetail>(h => h.EmpNo == Hp.EmpNo && h.SlotReleasedDate == date).ToList();
                if (list.Count <= 0)
                {
                    var affectedRows = objectContext.Database.ExecuteSqlCommand("holderdatainsertion @EmpNo={0},@ParkingSlotNumber={1},@CreatedDate={2},@SlotReleasedDate={3},@AllocationType={4},@OperationType={5}", Hp.EmpNo, Hp.ParkingSlotNumber, date, date, 0, 1);
                    Resdb = affectedRows = true ? 1 : 0;
                }
                else
                {
                    Resdb = 0;
                }
            }
            Assert.AreEqual(res.GetType(), Resdb.GetType());
        }
 public HolderPerson(IHolderPersonRepository holderPerson)
 {
     try
     {
         //Storing the object instance.
         this.Rep = holderPerson;
     }
     catch (Exception)
     {
         throw;
     }
 }