mirror of
https://github.com/vanitasvitae/Smack.git
synced 2025-09-09 17:19:39 +02:00
Add a PEP PubSubManager to PEPManager
This commit is contained in:
parent
5569782113
commit
4b3f757ed9
7 changed files with 72 additions and 39 deletions
|
@ -37,6 +37,10 @@ public abstract class AbstractOpenPgpIntegrationTest extends AbstractSmackIntegr
|
|||
protected final BareJid bob;
|
||||
protected final BareJid chloe;
|
||||
|
||||
protected final PEPManager alicePepManager;
|
||||
protected final PEPManager bobPepManager;
|
||||
protected final PEPManager chloePepManager;
|
||||
|
||||
protected AbstractOpenPgpIntegrationTest(SmackIntegrationTestEnvironment environment)
|
||||
throws XMPPException.XMPPErrorException, TestNotPossibleException, SmackException.NotConnectedException,
|
||||
InterruptedException, SmackException.NoResponseException {
|
||||
|
@ -54,9 +58,13 @@ public abstract class AbstractOpenPgpIntegrationTest extends AbstractSmackIntegr
|
|||
this.bob = bobConnection.getUser().asBareJid();
|
||||
this.chloe = chloeConnection.getUser().asBareJid();
|
||||
|
||||
OpenPgpPubSubUtil.deletePubkeysListNode(aliceConnection);
|
||||
OpenPgpPubSubUtil.deletePubkeysListNode(bobConnection);
|
||||
OpenPgpPubSubUtil.deletePubkeysListNode(chloeConnection);
|
||||
this.alicePepManager = PEPManager.getInstanceFor(aliceConnection);
|
||||
this.bobPepManager = PEPManager.getInstanceFor(bobConnection);
|
||||
this.chloePepManager = PEPManager.getInstanceFor(chloeConnection);
|
||||
|
||||
OpenPgpPubSubUtil.deletePubkeysListNode(alicePepManager);
|
||||
OpenPgpPubSubUtil.deletePubkeysListNode(bobPepManager);
|
||||
OpenPgpPubSubUtil.deletePubkeysListNode(chloePepManager);
|
||||
}
|
||||
|
||||
private static void throwIfPubSubNotSupported(XMPPConnection connection)
|
||||
|
|
|
@ -119,7 +119,7 @@ public class OXSecretKeyBackupIntegrationTest extends AbstractOpenPgpIntegration
|
|||
public void cleanUp()
|
||||
throws XMPPException.XMPPErrorException, SmackException.NotConnectedException, InterruptedException,
|
||||
SmackException.NoResponseException {
|
||||
OpenPgpPubSubUtil.deleteSecretKeyNode(aliceConnection);
|
||||
OpenPgpPubSubUtil.deleteSecretKeyNode(alicePepManager);
|
||||
|
||||
if (openPgpManager != null) {
|
||||
openPgpManager.stopMetadataListener();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue