def test_on_createWithConfig(self):

        xml = """
        <iq type='set' to='pubsub.example.org'
                       from='user@example.org'>
          <pubsub xmlns='http://jabber.org/protocol/pubsub'>
            <create node='mynode'/>
            <configure>
              <x xmlns='jabber:x:data' type='submit'>
                <field var='FORM_TYPE' type='hidden'>
                  <value>http://jabber.org/protocol/pubsub#node_config</value>
                </field>
                <field var='pubsub#deliver_payloads'><value>0</value></field>
                <field var='pubsub#persist_items'><value>1</value></field>
              </x>
            </configure>
          </pubsub>
        </iq>
        """

        def getConfigurationOptions():
            return {
                "pubsub#persist_items":
                    {"type": "boolean",
                     "label": "Persist items to storage"},
                "pubsub#deliver_payloads":
                    {"type": "boolean",
                     "label": "Deliver payloads with event notifications"}
                }

        def create(request):
            self.assertEqual({'pubsub#deliver_payloads': False,
                              'pubsub#persist_items': True},
                             request.options.getValues())
            return defer.succeed(None)

        self.resource.getConfigurationOptions = getConfigurationOptions
        self.resource.create = create
        verify.verifyObject(iwokkel.IPubSubResource, self.resource)
        return self.handleRequest(xml)
Get current video subtitle.
dataset/ETHPy150Open ralphm/wokkel/wokkel/test/test_pubsub.py/PubSubServiceTest.test_on_createWithConfig--crossover with--dataset/ETHPy150Open disqus/playa/playa/lib/vlc.py/libvlc_video_get_spu