public void IsJobMethod_ReturnsFalse_IfMethodHasNoSdkAttributes() { // Act bool actual = FunctionIndexer.IsJobMethod(typeof(FunctionIndexerTests).GetMethod("MethodWithUnboundOutParameterAndNoJobAttribute")); // Verify Assert.Equal(false, actual); }
public void IsJobMethod_ReturnsTrue_IfMethodHasJobParameterAttributes_FromExtensionAssemblies() { // Act bool actual = FunctionIndexer.IsJobMethod(typeof(FunctionIndexerTests).GetMethod("MethodWithExtensionJobParameterAttributes")); // Verify Assert.Equal(true, actual); }
public void IsJobMethod_ReturnsTrue_IfMethodHasJobAttributeButNoParameters() { // Act bool actual = FunctionIndexer.IsJobMethod(typeof(FunctionIndexerTests).GetMethod("MethodWithJobAttributeButNoParameters")); // Verify Assert.Equal(true, actual); }
public void IsJobMethod_ReturnsFalse_IfMethodHasNoParameters() { // Act bool actual = FunctionIndexer.IsJobMethod(typeof(FunctionIndexerTests).GetMethod("MethodWithNoParameters")); // Verify Assert.Equal(false, actual); }
public void IsJobMethod_ReturnsFalse_IfMethodHasUnresolvedGenericParameter() { // Arrange Mock <IFunctionIndex> indexMock = new Mock <IFunctionIndex>(); // Act bool actual = FunctionIndexer.IsJobMethod(typeof(FunctionIndexerTests).GetMethod("MethodWithGenericParameter")); // Verify Assert.Equal(false, actual); }
public void IsJobMethod_ReturnsFalse_IfMethodHasNoSdkAttributes() { // Arrange Mock <IFunctionIndex> indexMock = new Mock <IFunctionIndex>(); FunctionIndexer product = CreateProductUnderTest(); // Act bool actual = product.IsJobMethod(typeof(FunctionIndexerTests).GetMethod("MethodWithUnboundOutParameterAndNoJobAttribute")); // Verify Assert.Equal(false, actual); }
public void IsJobMethod_ReturnsTrue_IfMethodHasJobParameterAttributes() { // Arrange Mock <IFunctionIndex> indexMock = new Mock <IFunctionIndex>(); FunctionIndexer product = CreateProductUnderTest(); // Act bool actual = product.IsJobMethod(typeof(FunctionIndexerTests).GetMethod("MethodWithJobParameterAttributes")); // Verify Assert.Equal(true, actual); }
public void IsJobMethod_ReturnsTrue_IfMethodHasJobParameterAttributes_FromExtensionAssemblies() { // Arrange Mock <IFunctionIndex> indexMock = new Mock <IFunctionIndex>(); IExtensionRegistry extensions = new DefaultExtensionRegistry(); extensions.RegisterExtension <ITriggerBindingProvider>(new TestExtensionTriggerBindingProvider()); extensions.RegisterExtension <IBindingProvider>(new TestExtensionBindingProvider()); FunctionIndexer product = FunctionIndexerFactory.Create(extensionRegistry: extensions); // Act bool actual = product.IsJobMethod(typeof(FunctionIndexerTests).GetMethod("MethodWithExtensionJobParameterAttributes")); // Verify Assert.Equal(true, actual); }