@Test public void createTransactionFromTransparentRedirectSpecifyingLevel2Attributes() { TransactionRequest request = new TransactionRequest() .amount(TransactionAmount.AUTHORIZE.amount) .creditCard() .number(CreditCardNumber.VISA.number) .expirationDate("05/2009") .done(); TransactionRequest trParams = new TransactionRequest() .type(Transaction.Type.SALE) .taxAmount(new BigDecimal("10.00")) .taxExempt(true) .purchaseOrderNumber("12345"); String queryString = TestHelper.simulateFormPostForTR( gateway, trParams, request, gateway.transparentRedirect().url()); Result<Transaction> result = gateway.transparentRedirect().confirmTransaction(queryString); assertTrue(result.isSuccess()); Transaction transaction = result.getTarget(); assertEquals(new BigDecimal("10.00"), transaction.getTaxAmount()); assertTrue(transaction.isTaxExempt()); assertEquals("12345", transaction.getPurchaseOrderNumber()); }