Exemplo n.º 1
0
        public void RenderQueue_DrawStage_CatchNullInputs()
        {
            var commandQueue = Substitute.For <IRenderCommandQueue>();

            IRenderQueue queue = new RenderQueue(commandQueue);

            var stage  = Substitute.For <IDrawStage>();
            var camera = Substitute.For <ICamera2D>();
            var target = Substitute.For <IRenderTarget>();

            Assert.Throws <Yak2DException>(() => { queue.Draw(null, camera, target); });
            Assert.Throws <Yak2DException>(() => { queue.Draw(stage, null, target); });
            Assert.Throws <Yak2DException>(() => { queue.Draw(stage, camera, null); });
        }