コード例 #1
0
        public void When_Both_Conditions_Match_Alarm_Should_Be_Fired()
        {
            var result = new PriceMeScrapperResults {
                Price = 500, Title = "gopro"
            };

            var alert = new PriceOfProductBelowAlertConfiguration("GoPro", 500);

            Assert.True(alert.Fired(result));
        }
コード例 #2
0
        public void When_Title_Dont_Matches_But_Price_Is_Above_Condition_Alarm_Should_Be_False()
        {
            var result = new PriceMeScrapperResults {
                Price = 510, Title = "gepro"
            };

            var alert = new PriceOfProductBelowAlertConfiguration("GoPro", 500);

            Assert.False(alert.Fired(result));
        }