Пример #1
0
        public void ShouldReturnRectangleViewModel()
        {
            var rectangle        = new Rectangle();
            var viewModelFactory = new ShapeViewModelFactory();

            var shapeViewModel = viewModelFactory.Create(rectangle);

            Assert.IsInstanceOfType(shapeViewModel, typeof(RectangleViewModel));
        }
Пример #2
0
        public void ShouldReturnSquareViewModel()
        {
            var square           = new Square();
            var viewModelFactory = new ShapeViewModelFactory();

            var shapeViewModel = viewModelFactory.Create(square);

            Assert.IsInstanceOfType(shapeViewModel, typeof(SquareViewModel));
        }
Пример #3
0
        public void ShouldReturnCircleViewModel()
        {
            var circle           = new Circle();
            var viewModelFactory = new ShapeViewModelFactory();

            var shapeViewModel = viewModelFactory.Create(circle);

            Assert.IsInstanceOfType(shapeViewModel, typeof(CircleViewModel));
        }