### Question:
ExpressionFactory { public T createExpression(String left, String operand, String right) { if (operand.endsWith(Statement.EQUALS)) { return (T) new Equals(left, right); } if (operand.endsWith(Statement.REGEX)) { return (T) new Regex(left, right); } if (operand.endsWith(Statement.GREATER_THAN)) { return (T) new GreaterThan(left, right); } if (operand.endsWith(Statement.GREATER_EQUAL_THAN)) { return (T) new GreaterEqualThan(left, right); } if (operand.endsWith(Statement.LESS_THAN)) { return (T) new LessThan(left, right); } if (operand.endsWith(Statement.LESS_EQUAL_THAN)) { return (T) new LessEqualThan(left, right); } if (operand.endsWith(Statement.BETWEEN_TIME)) { return (T) new BetweenTime(left, right); } throw new UnsupportedOperationException("Operand " + operand + " is not a " + "recognised expression operand. HINT: check for spelling errors"); }  T createExpression(String left, String operand, String right);  }### Answer:
@Test public void createExpressionInputNullNotNullNullOutputUnsupportedOperationException() { final ExpressionFactory objectUnderTest = new ExpressionFactory(); final String left = null; final String operand = "NNO,_NONSCOWHON"; final String right = null; thrown.expect(UnsupportedOperationException.class); objectUnderTest.createExpression(left, operand, right); }
@Test public void createExpressionInputNullNullNullOutputNullPointerException() { final ExpressionFactory objectUnderTest = new ExpressionFactory(); final String left = null; final String operand = null; final String right = null; thrown.expect(NullPointerException.class); objectUnderTest.createExpression(left, operand, right); }
@Test public void createExpressionInputNotNullNotNullNotNullOutputUnsupportedOperationException() { final ExpressionFactory objectUnderTest = new ExpressionFactory(); final String left = " "; final String operand = "DDDEEFE"; final String right = " "; thrown.expect(UnsupportedOperationException.class); objectUnderTest.createExpression(left, operand, right); }