public void RegisteredUserViewStore() { MarketAnswer storeDetails = _storeBridge.ViewStoreInfo("OOF"); Assert.AreEqual((int)ViewStoreStatus.Success, storeDetails.Status); string expectedAnswer = "_storeName: OOF StoreAddress: BASA"; string receivedAnswer = "_storeName: " + storeDetails.ReportList[0] + " StoreAddress: " + storeDetails.ReportList[1]; Assert.AreEqual(expectedAnswer, receivedAnswer); }
public MarketAnswer ViewStoreInfo(string store) { if (real != null) { return(real.ViewStoreInfo(store)); } throw new NotImplementedException(); }
public void InvalidUserDidntEnterSystem() { _userWatchStore = UserDriver.getBridge(); _storeBridgeGuest = StoreShoppingDriver.getBridge(); _storeBridgeGuest.GetStoreShoppingService(_userWatchStore.GetUserSession()); MarketAnswer storeDetails = _storeBridgeGuest.ViewStoreInfo("OOF"); Assert.AreEqual((int)ViewStoreStatus.InvalidUser, storeDetails.Status); Assert.AreEqual(null, storeDetails.ReportList); }
public void SuccessInOpeningAStore() { MarketDB.Instance.InsertByForce(); SignUp("Pnina", "mishol", "7894", "12345678"); _storeBridge.GetStoreShoppingService(_bridgeSignUp.GetUserSession()); Assert.AreEqual((int)OpenStoreStatus.Success, _storeBridge.OpenStore("PninaStore", "Ben-Gurion").Status); MarketAnswer storeDetails = _storeBridge.ViewStoreInfo("PninaStore"); string expectedAnswer = "_storeName: PninaStore StoreAddress: Ben-Gurion"; string receivedAnswer = "_storeName: " + storeDetails.ReportList[0] + " StoreAddress: " + storeDetails.ReportList[1]; Assert.AreEqual(expectedAnswer, receivedAnswer); }
public void GuestViewStore() { _userWatchStore = UserDriver.getBridge(); _userWatchStore.EnterSystem(); _storeBridgeGuest = StoreShoppingDriver.getBridge(); _storeBridgeGuest.GetStoreShoppingService(_userWatchStore.GetUserSession()); MarketAnswer storeDetails = _storeBridgeGuest.ViewStoreInfo("OOF"); Assert.AreEqual((int)ViewStoreStatus.Success, storeDetails.Status); string expectedAnswer = "_storeName: OOF StoreAddress: BASA"; string receivedAnswer = "_storeName: " + storeDetails.ReportList[0] + " StoreAddress: " + storeDetails.ReportList[1]; Assert.AreEqual(expectedAnswer, receivedAnswer); }