//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes: //ORIGINAL LINE: @SuppressWarnings("unchecked") public void testExecuteWithInvocationContext() throws Exception //JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in .NET: public virtual void testExecuteWithInvocationContext() { // given a process application which extends the default one // - using a spy for verify the invocations TestApplicationWithoutEngine processApplication = spy(pa); ProcessApplicationReference processApplicationReference = mock(typeof(ProcessApplicationReference)); when(processApplicationReference.ProcessApplication).thenReturn(processApplication); // when execute with context InvocationContext invocationContext = new InvocationContext(mock(typeof(BaseDelegateExecution))); Context.executeWithinProcessApplication(mock(typeof(Callable)), processApplicationReference, invocationContext); // then the execute method should be invoked with context verify(processApplication).execute(any(typeof(Callable)), eq(invocationContext)); // and forward to call to the default execute method verify(processApplication).execute(any(typeof(Callable))); }
public override void setUp() { pa = new TestApplicationWithoutEngine(); pa.deploy(); }