Package org.apache.vysper.xmpp.delivery

Examples of org.apache.vysper.xmpp.delivery.RecordingStanzaRelay$Triple


        Assert.assertFalse(triples.hasNext());
    }

   
    public void testOnlyIgnoreErrorStanzas() throws Exception {
        RecordingStanzaRelay relay = new RecordingStanzaRelay();
        ReturnErrorToSenderFailureStrategy strategy = new ReturnErrorToSenderFailureStrategy(relay);
       
        Stanza stanza = XMPPCoreStanza.getWrapper(StanzaBuilder.createMessageStanza(FROM, TO, LANG, BODY)
            .addAttribute("type", "error")
            .build());

        strategy.process(stanza, Arrays.asList((DeliveryException)new RemoteServerNotFoundException()));

        Assert.assertFalse(relay.iterator().hasNext());
    }
View Full Code Here


        Assert.assertFalse(relay.iterator().hasNext());
    }
   
    public void testOnlyHandleCoreStanzas() throws Exception {
        RecordingStanzaRelay relay = new RecordingStanzaRelay();
        ReturnErrorToSenderFailureStrategy strategy = new ReturnErrorToSenderFailureStrategy(relay);
       
        Stanza stanza = StanzaBuilder.createMessageStanza(FROM, TO, LANG, BODY).build();
       
        try {
View Full Code Here

        relay.setServerRuntimeContext(serverContext);
        return new TestSessionContext(serverContext, sessionStateHolder);
    }

    public TestSessionContext(SessionStateHolder sessionStateHolder) {
        this(new DefaultServerRuntimeContext(new EntityImpl(null, "test", null), new RecordingStanzaRelay(),
                new MemoryStorageProviderRegistry()), sessionStateHolder);
    }
View Full Code Here

TOP

Related Classes of org.apache.vysper.xmpp.delivery.RecordingStanzaRelay$Triple

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.