data=new PingData(self, Util.createView(self, 1, self), true, "logical-name", null);
_testSize(data);
}
public static void testGossipData() throws Exception {
GossipData data;
final Address own=org.jgroups.util.UUID.randomUUID();
final Address coord=org.jgroups.util.UUID.randomUUID();
UUID.add((UUID)own, "own");
UUID.add((UUID)coord, "coord");
final PhysicalAddress physical_addr_1=new IpAddress("127.0.0.1", 7500);
final PhysicalAddress physical_addr_2=new IpAddress("192.168.1.5", 6000);
final PhysicalAddress physical_addr_3=new IpAddress("192.134.2.1", 6655);
_testSize(new GossipData());
data=new GossipData((byte)1);
_testSize(data);
data=new GossipData((byte)1, "DemoCluster", own, (List<Address>)null, null);
_testSize(data);
data=new GossipData((byte)1, "DemoCluster", own, Arrays.asList(own, coord), null);
_testSize(data);
data=new GossipData((byte)1, "DemoCluster", own, Arrays.asList(own, coord),
Arrays.asList(physical_addr_1, physical_addr_2, physical_addr_3));
_testSize(data);
List<PhysicalAddress> list=new ArrayList<PhysicalAddress>();
list.add(physical_addr_1);
list.add(physical_addr_2);
list.add(physical_addr_3);
data=new GossipData((byte)1, "DemoCluster", own, Arrays.asList(own, coord), list);
_testSize(data);
data=new GossipData((byte)1, "demo", own, "logical_name", null);
_testSize(data);
data=new GossipData((byte)1, "demo", own, new byte[]{'b', 'e', 'l', 'a'});
_testSize(data);
byte[] buffer=new byte[10];
buffer[2]='B';
buffer[3]='e';
buffer[4]='l';
buffer[5]='a';
data=new GossipData((byte)1, "demo", own, buffer, 2, 4);
_testSize(data);
}