@Test
  public void testGetPunchOutCredential() {
    when(this.credentialDao.getPunchOutCredential(Mockito.anyString(), Mockito.anyString()))
        .thenReturn(credentialModel);
    final PunchOutCredentialModel punchoutCredentialModel =
        punchoutCredentialService.getPunchOutCredential(
            credential.getDomain(), credential.getIdentity().getContent().get(0).toString());

    assertNotNull(punchoutCredentialModel);
    assertEquals(SHARED_SECRET, punchoutCredentialModel.getSharedsecret());
  }
  @Before
  public void setUp() throws FileNotFoundException {
    requestXML = PunchOutUtils.unmarshallCXMLFromFile("b2bpunchout/test/punchoutSetupRequest.xml");
    header = (Header) requestXML.getHeaderOrMessageOrRequestOrResponse().get(0);
    credential = header.getSender().getCredential().iterator().next();

    when(customerModel.getEmail()).thenReturn(DUMMY_EMAIL);
    when(mappingModel.getB2bCustomer()).thenReturn(customerModel);
    when(credentialModel.getB2BCustomerPunchOutCredentialMapping()).thenReturn(mappingModel);
    when(credentialModel.getSharedsecret()).thenReturn(SHARED_SECRET);
    punchoutCredentialService.setCredentialDao(credentialDao);
  }