mirror of
https://github.com/vanitasvitae/Smack.git
synced 2025-12-06 02:51:11 +01:00
Rename 'serviceName' to 'xmppServiceDomain'
Also use 'null' as default value for the resource, to enforce server generated resources. Fixes Smack-665
This commit is contained in:
parent
0c8199650b
commit
f369a009ac
38 changed files with 116 additions and 104 deletions
|
|
@ -56,7 +56,7 @@ public class CompressionTest extends SmackTestCase {
|
|||
// Request the version of the server
|
||||
Version version = new Version();
|
||||
version.setType(IQ.Type.get);
|
||||
version.setTo(getServiceName());
|
||||
version.setTo(getXMPPServiceDomain());
|
||||
|
||||
// Create a packet collector to listen for a response.
|
||||
PacketCollector collector = connection.createPacketCollector(new PacketIDFilter(version.getStanzaId()));
|
||||
|
|
@ -84,7 +84,7 @@ public class CompressionTest extends SmackTestCase {
|
|||
*/
|
||||
protected void setUp() throws Exception {
|
||||
super.setUp();
|
||||
XMPPTCPConnection setupConnection = new XMPPConnection(getServiceName());
|
||||
XMPPTCPConnection setupConnection = new XMPPConnection(getXMPPServiceDomain());
|
||||
setupConnection.connect();
|
||||
if (!setupConnection.getAccountManager().supportsAccountCreation())
|
||||
fail("Server does not support account creation");
|
||||
|
|
|
|||
|
|
@ -114,7 +114,7 @@ public class ServiceDiscoveryManagerTest extends SmackTestCase {
|
|||
public void testDiscoverPublishItemsSupport() {
|
||||
try {
|
||||
boolean canPublish = ServiceDiscoveryManager.getInstanceFor(getConnection(0))
|
||||
.canPublishItems(getServiceName());
|
||||
.canPublishItems(getXMPPServiceDomain());
|
||||
assertFalse("Wildfire does not support publishing...so far!!", canPublish);
|
||||
}
|
||||
catch (Exception e) {
|
||||
|
|
@ -135,7 +135,7 @@ public class ServiceDiscoveryManagerTest extends SmackTestCase {
|
|||
itemsToPublish.addItem(itemToPublish);
|
||||
|
||||
try {
|
||||
ServiceDiscoveryManager.getInstanceFor(getConnection(0)).publishItems(getServiceName(),
|
||||
ServiceDiscoveryManager.getInstanceFor(getConnection(0)).publishItems(getXMPPServiceDomain(),
|
||||
itemsToPublish);
|
||||
}
|
||||
catch (Exception e) {
|
||||
|
|
|
|||
|
|
@ -224,7 +224,7 @@ public class MultiUserChatTest extends SmackTestCase {
|
|||
try {
|
||||
// Anonymous user joins the new room
|
||||
ConnectionConfiguration connectionConfiguration =
|
||||
new ConnectionConfiguration(getHost(), getPort(), getServiceName());
|
||||
new ConnectionConfiguration(getHost(), getPort(), getXMPPServiceDomain());
|
||||
XMPPTCPConnection anonConnection = new XMPPConnection(connectionConfiguration);
|
||||
anonConnection.connect();
|
||||
anonConnection.loginAnonymously();
|
||||
|
|
@ -405,7 +405,7 @@ public class MultiUserChatTest extends SmackTestCase {
|
|||
|
||||
public void testDiscoverMUCService() {
|
||||
try {
|
||||
Collection<String> services = MultiUserChat.getServiceNames(getConnection(1));
|
||||
Collection<String> services = MultiUserChat.getXMPPServiceDomains(getConnection(1));
|
||||
assertFalse("No MUC service was found", services.isEmpty());
|
||||
|
||||
// Discover the hosted rooms by the chat service.
|
||||
|
|
@ -1736,7 +1736,7 @@ public class MultiUserChatTest extends SmackTestCase {
|
|||
XMPPTCPConnection[] conns = new XMPPConnection[5];
|
||||
for (int i = 0; i < conns.length; i++) {
|
||||
ConnectionConfiguration connectionConfiguration =
|
||||
new ConnectionConfiguration(getHost(), getPort(), getServiceName());
|
||||
new ConnectionConfiguration(getHost(), getPort(), getXMPPServiceDomain());
|
||||
connectionConfiguration.setSecurityMode(ConnectionConfiguration.SecurityMode.disabled);
|
||||
conns[i] = new XMPPTCPConnection(connectionConfiguration);
|
||||
conns[i].connect();
|
||||
|
|
|
|||
|
|
@ -52,7 +52,7 @@ public class TestEvents extends SmackTestCase
|
|||
|
||||
private String getService()
|
||||
{
|
||||
return "pubsub." + getServiceName();
|
||||
return "pubsub." + getXMPPServiceDomain();
|
||||
}
|
||||
|
||||
public void testCreateAndGetNode() throws Exception
|
||||
|
|
|
|||
|
|
@ -87,6 +87,6 @@ abstract public class PubSubTestCase extends SmackTestCase
|
|||
|
||||
protected String getService()
|
||||
{
|
||||
return "pubsub." + getServiceName();
|
||||
return "pubsub." + getXMPPServiceDomain();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue