コード例 #1
0
        private void TryParameter(Object[] param)
        {
            LastElementViewFactory factory = new LastElementViewFactory();

            factory.SetViewParameters(SupportStatementContextFactory.MakeViewContext(), TestViewSupport.ToExprListBean(param));
            Assert.IsTrue(factory.MakeView(SupportStatementContextFactory.MakeAgentInstanceViewFactoryContext()) is LastElementView);
        }
コード例 #2
0
 private void TryInvalidParameter(Object param)
 {
     try
     {
         LastElementViewFactory factory = new LastElementViewFactory();
         factory.SetViewParameters(SupportStatementContextFactory.MakeViewContext(), TestViewSupport.ToExprListBean(new Object[] { param }));
         Assert.Fail();
     }
     catch (ViewParameterException ex)
     {
         // expected
     }
 }