public void FloatingStop()
        {
            var factory      = new StopTypeFactory();
            var floatingStop = factory.Create(StopTypeValue.Floating);

            Assert.IsType <FloatingStop>(floatingStop);
        }
        public void SmartStop()
        {
            var factory   = new StopTypeFactory();
            var smartStop = factory.Create(StopTypeValue.Smart);

            Assert.IsType <SmartStop>(smartStop);
        }
        public void WhenUnknownUseTrailingStop()
        {
            var factory = new StopTypeFactory();
            var stop    = factory.Create((StopTypeValue)10);

            Assert.IsType <TrailingStop>(stop);
        }
        public void TrailingStop()
        {
            var factory      = new StopTypeFactory();
            var trailingStop = factory.Create(StopTypeValue.Trailing);

            Assert.IsType <TrailingStop>(trailingStop);
        }
Beispiel #5
0
 public Calculator(StopTypeFactory factory)
 {
     _factory = factory;
 }