use of com.sun.xml.ws.policy.sourcemodel.AssertionData in project metro-jax-ws by eclipse-ee4j.
the class ManagedClientAssertionTest method testNoId.
/**
* Test of getId method, of class ManagedClientAssertion.
*/
public void testNoId() throws AssertionCreationException {
final HashMap<QName, String> attributes = new HashMap<QName, String>();
final AssertionData data = AssertionData.createAssertionData(ManagedClientAssertion.MANAGED_CLIENT_QNAME, null, attributes, false, false);
final ManagedClientAssertion instance = new ManagedClientAssertion(data, null);
final String result = instance.getId();
assertNull(result);
}
use of com.sun.xml.ws.policy.sourcemodel.AssertionData in project metro-jax-ws by eclipse-ee4j.
the class ManagedClientAssertionTest method testIsManagementEnabledTrue.
public void testIsManagementEnabledTrue() throws AssertionCreationException {
final HashMap<QName, String> attributes = new HashMap<QName, String>();
attributes.put(ID_ATTRIBUTE_QNAME, "id1");
attributes.put(MANAGEMENT_ATTRIBUTE_QNAME, "true");
final AssertionData data = AssertionData.createAssertionData(ManagedClientAssertion.MANAGED_CLIENT_QNAME, null, attributes, false, false);
final ManagedClientAssertion instance = new ManagedClientAssertion(data, null);
final boolean result = instance.isManagementEnabled();
assertFalse(result);
}
use of com.sun.xml.ws.policy.sourcemodel.AssertionData in project metro-jax-ws by eclipse-ee4j.
the class ManagedClientAssertionTest method testGetStart.
/**
* Test of getStart method, of class ManagedClientAssertion.
*/
public void testGetStart() throws AssertionCreationException {
final HashMap<QName, String> attributes = new HashMap<QName, String>();
attributes.put(ID_ATTRIBUTE_QNAME, "id1");
attributes.put(START_ATTRIBUTE_QNAME, "notify");
final AssertionData data = AssertionData.createAssertionData(ManagedClientAssertion.MANAGED_CLIENT_QNAME, null, attributes, false, false);
ManagedClientAssertion instance = new ManagedClientAssertion(data, null);
String expResult = "notify";
String result = instance.getStart();
assertEquals(expResult, result);
}
use of com.sun.xml.ws.policy.sourcemodel.AssertionData in project metro-jax-ws by eclipse-ee4j.
the class ManagedClientAssertionTest method testMonitoringAttributeOff.
public void testMonitoringAttributeOff() throws AssertionCreationException {
final HashMap<QName, String> attributes = new HashMap<QName, String>();
attributes.put(ID_ATTRIBUTE_QNAME, "id1");
attributes.put(MONITORING_ATTRIBUTE_QNAME, "off");
final AssertionData data = AssertionData.createAssertionData(ManagedClientAssertion.MANAGED_CLIENT_QNAME, null, attributes, false, false);
final ManagedClientAssertion instance = new ManagedClientAssertion(data, null);
final Setting result = instance.monitoringAttribute();
assertSame(result, Setting.OFF);
}
use of com.sun.xml.ws.policy.sourcemodel.AssertionData in project metro-jax-ws by eclipse-ee4j.
the class ManagedClientAssertionTest method testMonitoringAttributeFalse.
public void testMonitoringAttributeFalse() throws AssertionCreationException {
final HashMap<QName, String> attributes = new HashMap<QName, String>();
attributes.put(ID_ATTRIBUTE_QNAME, "id1");
attributes.put(MONITORING_ATTRIBUTE_QNAME, "false");
final AssertionData data = AssertionData.createAssertionData(ManagedClientAssertion.MANAGED_CLIENT_QNAME, null, attributes, false, false);
final ManagedClientAssertion instance = new ManagedClientAssertion(data, null);
final Setting result = instance.monitoringAttribute();
assertSame(result, Setting.OFF);
}
Aggregations