You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
35 lines
718 B
C#
35 lines
718 B
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
using Xunit;
|
|
|
|
using DesignPatternStudy.Learn;
|
|
using DesignPatternStudy.Learn.StrategyPattern.NoPattern;
|
|
|
|
namespace DesignPatternStudy.Learn.StrategyPattern
|
|
{
|
|
public class NoStrategyPatternTest:IDisposable
|
|
{
|
|
NoStrategyPattern noStrategy;
|
|
|
|
public NoStrategyPatternTest()
|
|
{
|
|
noStrategy = new NoStrategyPattern();
|
|
}
|
|
|
|
[Fact]
|
|
public void GetPriceTest()
|
|
{
|
|
var price1 = noStrategy.GetPrice(100m,1);
|
|
Assert.Equal(90, price1);
|
|
}
|
|
|
|
public void Dispose()
|
|
{
|
|
|
|
}
|
|
}
|
|
}
|