REST: Node and item manipulation using REST API - JSON - #4728

Test duration: 9.145s

Passed Tests
tigase.tests.pubsub.TestRestApiUsingJSON
configureNodes 1.111s
2019-11-20 21:04:04 |

2019-11-20 21:04:04 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-11-20 21:04:04 | ------------------------------------

2019-11-20 21:04:04 | [Mutex] waiting for: [configured:node:node-220b3cf9-d8f4-461f-bb63-4e6bbdc6d5fd:node-66fc369c-deef-47b5-8e78-1f8c0dffe533]

2019-11-20 21:04:04 | [Mutex] received everything.

2019-11-20 21:04:04 | [Mutex] isItemNotified: configured:node:node-220b3cf9-d8f4-461f-bb63-4e6bbdc6d5fd:node-66fc369c-deef-47b5-8e78-1f8c0dffe533 :: true

2019-11-20 21:04:05 | [Mutex] waiting for: [received:nodes:fb4c6d22-f554-422b-9a9a-cba211d28238:localhost]

2019-11-20 21:04:05 | [Mutex] received everything.

2019-11-20 21:04:05 | [Mutex] isItemNotified: received:node:fb4c6d22-f554-422b-9a9a-cba211d28238:localhost:node-220b3cf9-d8f4-461f-bb63-4e6bbdc6d5fd:Node 220b3cf9-d8f4-461f-bb63-4e6bbdc6d5fd :: true

2019-11-20 21:04:05 | [Mutex] waiting for: [received:nodes:1fbb9819-7960-4643-933a-450afe2de15a:localhost]

2019-11-20 21:04:05 | [Mutex] received everything.

2019-11-20 21:04:05 | [Mutex] isItemNotified: received:node:1fbb9819-7960-4643-933a-450afe2de15a:localhost:node-220b3cf9-d8f4-461f-bb63-4e6bbdc6d5fd:Node 220b3cf9-d8f4-461f-bb63-4e6bbdc6d5fd :: false

createNodes 1.803s
2019-11-20 21:04:01 |

2019-11-20 21:04:01 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-11-20 21:04:01 | ------------------------------------

2019-11-20 21:04:02 | on localhost executing action create-node with content type application/json and payload:
{
    "owner": "admin@localhost",
    "pubsub#node_type": "leaf",
    "node": "node-220b3cf9-d8f4-461f-bb63-4e6bbdc6d5fd",
    "pubsub#title": "Node 220b3cf9-d8f4-461f-bb63-4e6bbdc6d5fd"
}

2019-11-20 21:04:02 | from localhost for action create-node got result code 200 and payload
{
    "Note": "Operation successful"
}

2019-11-20 21:04:03 | [Mutex] waiting for: [received:nodes:4bb012a7-471a-4b18-9fc8-701313991c58:localhost]

2019-11-20 21:04:03 | [Mutex] received everything.

2019-11-20 21:04:03 | [Mutex] isItemNotified: received:node:4bb012a7-471a-4b18-9fc8-701313991c58:localhost:node-220b3cf9-d8f4-461f-bb63-4e6bbdc6d5fd:Node 220b3cf9-d8f4-461f-bb63-4e6bbdc6d5fd :: true

createSubnodes 1.024s
2019-11-20 21:04:03 |

2019-11-20 21:04:03 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-11-20 21:04:03 | ------------------------------------

2019-11-20 21:04:03 | on localhost executing action create-node with content type application/json and payload:
{
    "owner": "admin@localhost",
    "pubsub#node_type": "collection",
    "node": "node-66fc369c-deef-47b5-8e78-1f8c0dffe533",
    "pubsub#title": "Node 66fc369c-deef-47b5-8e78-1f8c0dffe533"
}

2019-11-20 21:04:03 | from localhost for action create-node got result code 200 and payload
{
    "Note": "Operation successful"
}

2019-11-20 21:04:04 | [Mutex] waiting for: [received:nodes:0e9cc5e8-9144-4f14-8014-afa5504577ee:localhost]

2019-11-20 21:04:04 | [Mutex] received everything.

2019-11-20 21:04:04 | [Mutex] isItemNotified: received:node:0e9cc5e8-9144-4f14-8014-afa5504577ee:localhost:node-66fc369c-deef-47b5-8e78-1f8c0dffe533:Node 66fc369c-deef-47b5-8e78-1f8c0dffe533 :: true

deleteNodes 1.022s
2019-11-20 21:04:09 |

2019-11-20 21:04:09 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-11-20 21:04:09 | ------------------------------------

2019-11-20 21:04:09 | on localhost executing action delete-node with content type application/json and payload:
{
    "node": "node-66fc369c-deef-47b5-8e78-1f8c0dffe533"
}

2019-11-20 21:04:09 | from localhost for action delete-node got result code 200 and payload
{
    "Note": "Operation successful"
}

2019-11-20 21:04:10 | [Mutex] waiting for: [received:nodes:2d23a89b-3302-4b4f-aefb-4fb487615b9d:localhost]

2019-11-20 21:04:10 | [Mutex] waiting for: [received:nodes:2d23a89b-3302-4b4f-aefb-4fb487615b9d:localhost]

2019-11-20 21:04:10 | [Mutex] received everything.

2019-11-20 21:04:10 | [Mutex] isItemNotified: received:node:2d23a89b-3302-4b4f-aefb-4fb487615b9d:localhost:node-66fc369c-deef-47b5-8e78-1f8c0dffe533:Node 66fc369c-deef-47b5-8e78-1f8c0dffe533 :: false

deleteSubnodes 1.057s
2019-11-20 21:04:08 |

2019-11-20 21:04:08 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-11-20 21:04:08 | ------------------------------------

2019-11-20 21:04:08 | on localhost executing action delete-node with content type application/json and payload:
{
    "node": "node-220b3cf9-d8f4-461f-bb63-4e6bbdc6d5fd"
}

2019-11-20 21:04:08 | from localhost for action delete-node got result code 200 and payload
{
    "Note": "Operation successful"
}

2019-11-20 21:04:09 | [Mutex] waiting for: [received:nodes:3a508ec2-7c0f-44e2-adc2-7d1ffe2228ea:localhost]

2019-11-20 21:04:09 | [Mutex] received everything.

2019-11-20 21:04:09 | [Mutex] isItemNotified: received:node:3a508ec2-7c0f-44e2-adc2-7d1ffe2228ea:localhost:node-220b3cf9-d8f4-461f-bb63-4e6bbdc6d5fd:Node 220b3cf9-d8f4-461f-bb63-4e6bbdc6d5fd :: false

2019-11-20 21:04:09 | [Mutex] waiting for: [received:nodes:59a7054c-fb35-4e4f-a102-2d58bf5062b0:localhost]

2019-11-20 21:04:09 | [Mutex] received everything.

2019-11-20 21:04:09 | [Mutex] isItemNotified: received:node:59a7054c-fb35-4e4f-a102-2d58bf5062b0:localhost:node-220b3cf9-d8f4-461f-bb63-4e6bbdc6d5fd:Node 220b3cf9-d8f4-461f-bb63-4e6bbdc6d5fd :: false

publishItemsToNodes 0.025s
2019-11-20 21:04:06 |

2019-11-20 21:04:06 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-11-20 21:04:06 | ------------------------------------

2019-11-20 21:04:06 | on localhost executing action publish-item with content type application/json and payload:
{
    "node": "node-220b3cf9-d8f4-461f-bb63-4e6bbdc6d5fd",
    "entry": "<test>item-f2e0ff80-ed1d-4205-bf27-27857c80340a</test>",
    "item-id": "item-f2e0ff80-ed1d-4205-bf27-27857c80340a"
}

2019-11-20 21:04:06 | from localhost for action publish-item got result code 200 and payload
{
    "Note": "Operation successful",
    "item-id": "item-f2e0ff80-ed1d-4205-bf27-27857c80340a"
}

2019-11-20 21:04:06 | [Mutex] waiting for: [published:item:notifieditem-f2e0ff80-ed1d-4205-bf27-27857c80340a:admin@localhost]

2019-11-20 21:04:06 | [Mutex] received everything.

2019-11-20 21:04:06 | [Mutex] isItemNotified: published:item:notifieditem-f2e0ff80-ed1d-4205-bf27-27857c80340a:admin@localhost :: true

retractItemsFromNodes 0.055s
2019-11-20 21:04:07 |

2019-11-20 21:04:07 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-11-20 21:04:07 | ------------------------------------

2019-11-20 21:04:07 | on localhost executing action delete-item with content type application/json and payload:
{
    "node": "node-220b3cf9-d8f4-461f-bb63-4e6bbdc6d5fd",
    "item-id": "item-f2e0ff80-ed1d-4205-bf27-27857c80340a"
}

2019-11-20 21:04:07 | from localhost for action delete-item got result code 200 and payload
{
    "Note": "Operation successful",
    "item-id": "item-f2e0ff80-ed1d-4205-bf27-27857c80340a"
}

2019-11-20 21:04:07 | [Mutex] received everything.

2019-11-20 21:04:07 | [Mutex] isItemNotified: retracted:item:notifieditem-f2e0ff80-ed1d-4205-bf27-27857c80340a:admin@localhost :: true

retrieveItemsFromNodes 0.083s
2019-11-20 21:04:06 |

2019-11-20 21:04:06 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-11-20 21:04:06 | ------------------------------------

2019-11-20 21:04:06 | on localhost executing action retrieve-item with content type application/json and payload:
{
    "node": "node-220b3cf9-d8f4-461f-bb63-4e6bbdc6d5fd",
    "item-id": "item-f2e0ff80-ed1d-4205-bf27-27857c80340a"
}

2019-11-20 21:04:06 | from localhost for action retrieve-item got result code 200 and payload
{
    "title": "Retrive PubSub node item",
    "node": "node-220b3cf9-d8f4-461f-bb63-4e6bbdc6d5fd",
    "item-id": "item-f2e0ff80-ed1d-4205-bf27-27857c80340a",
    "item": [
        "<item id=\"item-f2e0ff80-ed1d-4205-bf27-27857c80340a\"><test>item-f2e0ff80-ed1d-4205-bf27-27857c80340a</test></item>"
    ]
}

2019-11-20 21:04:06 | [Mutex] notify: [retrieved:item:item-f2e0ff80-ed1d-4205-bf27-27857c80340a:payload-matches:true:localhost]

2019-11-20 21:04:06 | [Mutex] received everything.

2019-11-20 21:04:06 | [Mutex] isItemNotified: retrieved:item:item-f2e0ff80-ed1d-4205-bf27-27857c80340a:payload-matches:true:localhost :: true

retrieveUserSubscriptions 0.051s
2019-11-20 21:04:06 |

2019-11-20 21:04:06 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-11-20 21:04:06 | ------------------------------------

2019-11-20 21:04:06 | on localhost executing action retrieve-user-subscriptions with content type application/json and payload:
{
    "jid": "admin@localhost"
}

2019-11-20 21:04:07 | from localhost for action retrieve-user-subscriptions got result code 200 and payload
{
    "nodes": [
        "node-220b3cf9-d8f4-461f-bb63-4e6bbdc6d5fd",
        "node-66fc369c-deef-47b5-8e78-1f8c0dffe533"
    ]
}

retrieveUserSubscriptionsWithRegex 0.051s
2019-11-20 21:04:07 |

2019-11-20 21:04:07 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-11-20 21:04:07 | ------------------------------------

2019-11-20 21:04:07 | on localhost executing action retrieve-user-subscriptions with content type application/json and payload:
{
    "jid": "admin@localhost",
    "node-pattern": "(?!node-220b3cf9-d8f4-461f-bb63-4e6bbdc6d5fd)"
}

2019-11-20 21:04:07 | from localhost for action retrieve-user-subscriptions got result code 200 and payload
{
    "nodes": [
       
    ]
}

subscribeNodes 1.012s
2019-11-20 21:04:05 |

2019-11-20 21:04:05 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-11-20 21:04:05 | ------------------------------------

2019-11-20 21:04:05 | on localhost executing action subscribe-node with content type application/json and payload:
{
    "node": "node-220b3cf9-d8f4-461f-bb63-4e6bbdc6d5fd",
    "jids": [
        "admin@localhost"
    ]
}

2019-11-20 21:04:05 | from localhost for action subscribe-node got result code 200 and payload
{
    "Note": "Operation successful"
}

unsubscribeNodes 1.079s
2019-11-20 21:04:07 |

2019-11-20 21:04:07 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-11-20 21:04:07 | ------------------------------------

2019-11-20 21:04:07 | on localhost executing action unsubscribe-node with content type application/json and payload:
{
    "node": "node-220b3cf9-d8f4-461f-bb63-4e6bbdc6d5fd",
    "jids": [
        "admin@localhost"
    ]
}

2019-11-20 21:04:07 | from localhost for action unsubscribe-node got result code 200 and payload
{
    "Note": "Operation successful"
}