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

Test duration: 8.846s

Passed Tests
tigase.tests.pubsub.TestRestApiUsingJSON
configureNodes 1.114s
2020-01-02 19:51:40 |

2020-01-02 19:51:40 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-01-02 19:51:40 | ------------------------------------

2020-01-02 19:51:40 | [Mutex] waiting for: [configured:node:node-b5398330-6675-4fdc-8866-d00ab3b625ab:node-9c99fd0b-3f9f-4681-b35c-13e475b31207]

2020-01-02 19:51:40 | [Mutex] received everything.

2020-01-02 19:51:40 | [Mutex] isItemNotified: configured:node:node-b5398330-6675-4fdc-8866-d00ab3b625ab:node-9c99fd0b-3f9f-4681-b35c-13e475b31207 :: true

2020-01-02 19:51:41 | [Mutex] waiting for: [received:nodes:1f00cc1c-3275-4047-96a9-e1760255ce9b:localhost]

2020-01-02 19:51:41 | [Mutex] received everything.

2020-01-02 19:51:41 | [Mutex] isItemNotified: received:node:1f00cc1c-3275-4047-96a9-e1760255ce9b:localhost:node-b5398330-6675-4fdc-8866-d00ab3b625ab:Node b5398330-6675-4fdc-8866-d00ab3b625ab :: true

2020-01-02 19:51:41 | [Mutex] waiting for: [received:nodes:f5a9ba18-09c5-453c-b63b-799b995ffcfb:localhost]

2020-01-02 19:51:41 | [Mutex] waiting for: [received:nodes:f5a9ba18-09c5-453c-b63b-799b995ffcfb:localhost]

2020-01-02 19:51:41 | [Mutex] received everything.

2020-01-02 19:51:41 | [Mutex] isItemNotified: received:node:f5a9ba18-09c5-453c-b63b-799b995ffcfb:localhost:node-b5398330-6675-4fdc-8866-d00ab3b625ab:Node b5398330-6675-4fdc-8866-d00ab3b625ab :: false

createNodes 1.604s
2020-01-02 19:51:37 |

2020-01-02 19:51:37 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-01-02 19:51:37 | ------------------------------------

2020-01-02 19:51:38 | on localhost executing action create-node with content type application/json and payload:
{
    "owner": "admin@localhost",
    "pubsub#node_type": "leaf",
    "node": "node-b5398330-6675-4fdc-8866-d00ab3b625ab",
    "pubsub#title": "Node b5398330-6675-4fdc-8866-d00ab3b625ab"
}

2020-01-02 19:51:38 | from localhost for action create-node got result code 200 and payload
{
    "Note": "Operation successful"
}

2020-01-02 19:51:39 | [Mutex] waiting for: [received:nodes:b108b190-4b20-497b-b182-15d1805dcfd0:localhost]

2020-01-02 19:51:39 | [Mutex] received everything.

2020-01-02 19:51:39 | [Mutex] isItemNotified: received:node:b108b190-4b20-497b-b182-15d1805dcfd0:localhost:node-b5398330-6675-4fdc-8866-d00ab3b625ab:Node b5398330-6675-4fdc-8866-d00ab3b625ab :: true

createSubnodes 1.024s
2020-01-02 19:51:39 |

2020-01-02 19:51:39 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-01-02 19:51:39 | ------------------------------------

2020-01-02 19:51:39 | on localhost executing action create-node with content type application/json and payload:
{
    "owner": "admin@localhost",
    "pubsub#node_type": "collection",
    "node": "node-9c99fd0b-3f9f-4681-b35c-13e475b31207",
    "pubsub#title": "Node 9c99fd0b-3f9f-4681-b35c-13e475b31207"
}

2020-01-02 19:51:39 | from localhost for action create-node got result code 200 and payload
{
    "Note": "Operation successful"
}

2020-01-02 19:51:40 | [Mutex] waiting for: [received:nodes:3a6b234c-b27d-4f54-9dc6-b15e34b37685:localhost]

2020-01-02 19:51:40 | [Mutex] received everything.

2020-01-02 19:51:40 | [Mutex] isItemNotified: received:node:3a6b234c-b27d-4f54-9dc6-b15e34b37685:localhost:node-9c99fd0b-3f9f-4681-b35c-13e475b31207:Node 9c99fd0b-3f9f-4681-b35c-13e475b31207 :: true

deleteNodes 1.020s
2020-01-02 19:51:44 |

2020-01-02 19:51:44 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-01-02 19:51:44 | ------------------------------------

2020-01-02 19:51:44 | on localhost executing action delete-node with content type application/json and payload:
{
    "node": "node-9c99fd0b-3f9f-4681-b35c-13e475b31207"
}

2020-01-02 19:51:44 | from localhost for action delete-node got result code 200 and payload
{
    "Note": "Operation successful"
}

2020-01-02 19:51:45 | [Mutex] waiting for: [received:nodes:a8c7fd43-872f-4cd0-baaa-296c3759f532:localhost]

2020-01-02 19:51:45 | [Mutex] received everything.

2020-01-02 19:51:45 | [Mutex] isItemNotified: received:node:a8c7fd43-872f-4cd0-baaa-296c3759f532:localhost:node-9c99fd0b-3f9f-4681-b35c-13e475b31207:Node 9c99fd0b-3f9f-4681-b35c-13e475b31207 :: false

deleteSubnodes 1.036s
2020-01-02 19:51:43 |

2020-01-02 19:51:43 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-01-02 19:51:43 | ------------------------------------

2020-01-02 19:51:43 | on localhost executing action delete-node with content type application/json and payload:
{
    "node": "node-b5398330-6675-4fdc-8866-d00ab3b625ab"
}

2020-01-02 19:51:43 | from localhost for action delete-node got result code 200 and payload
{
    "Note": "Operation successful"
}

2020-01-02 19:51:44 | [Mutex] waiting for: [received:nodes:288a6d97-7db9-4690-a540-837d4de6be4b:localhost]

2020-01-02 19:51:44 | [Mutex] received everything.

2020-01-02 19:51:44 | [Mutex] isItemNotified: received:node:288a6d97-7db9-4690-a540-837d4de6be4b:localhost:node-b5398330-6675-4fdc-8866-d00ab3b625ab:Node b5398330-6675-4fdc-8866-d00ab3b625ab :: false

2020-01-02 19:51:44 | [Mutex] waiting for: [received:nodes:488ddb48-2e98-47f6-84ad-48158c8f30da:localhost]

2020-01-02 19:51:44 | [Mutex] received everything.

2020-01-02 19:51:44 | [Mutex] isItemNotified: received:node:488ddb48-2e98-47f6-84ad-48158c8f30da:localhost:node-b5398330-6675-4fdc-8866-d00ab3b625ab:Node b5398330-6675-4fdc-8866-d00ab3b625ab :: false

publishItemsToNodes 0.045s
2020-01-02 19:51:42 |

2020-01-02 19:51:42 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-01-02 19:51:42 | ------------------------------------

2020-01-02 19:51:42 | on localhost executing action publish-item with content type application/json and payload:
{
    "node": "node-b5398330-6675-4fdc-8866-d00ab3b625ab",
    "entry": "<test>item-0b7567f3-8e0d-491a-8e20-a17b11e5fd29</test>",
    "item-id": "item-0b7567f3-8e0d-491a-8e20-a17b11e5fd29"
}

2020-01-02 19:51:42 | from localhost for action publish-item got result code 200 and payload
{
    "Note": "Operation successful",
    "item-id": "item-0b7567f3-8e0d-491a-8e20-a17b11e5fd29"
}

2020-01-02 19:51:42 | [Mutex] waiting for: [published:item:notifieditem-0b7567f3-8e0d-491a-8e20-a17b11e5fd29:admin@localhost]

2020-01-02 19:51:42 | [Mutex] received everything.

2020-01-02 19:51:42 | [Mutex] isItemNotified: published:item:notifieditem-0b7567f3-8e0d-491a-8e20-a17b11e5fd29:admin@localhost :: true

retractItemsFromNodes 0.063s
2020-01-02 19:51:42 |

2020-01-02 19:51:42 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-01-02 19:51:42 | ------------------------------------

2020-01-02 19:51:42 | on localhost executing action delete-item with content type application/json and payload:
{
    "node": "node-b5398330-6675-4fdc-8866-d00ab3b625ab",
    "item-id": "item-0b7567f3-8e0d-491a-8e20-a17b11e5fd29"
}

2020-01-02 19:51:42 | from localhost for action delete-item got result code 200 and payload
{
    "Note": "Operation successful",
    "item-id": "item-0b7567f3-8e0d-491a-8e20-a17b11e5fd29"
}

2020-01-02 19:51:42 | [Mutex] received everything.

2020-01-02 19:51:42 | [Mutex] isItemNotified: retracted:item:notifieditem-0b7567f3-8e0d-491a-8e20-a17b11e5fd29:admin@localhost :: true

retrieveItemsFromNodes 0.057s
2020-01-02 19:51:42 |

2020-01-02 19:51:42 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-01-02 19:51:42 | ------------------------------------

2020-01-02 19:51:42 | on localhost executing action retrieve-item with content type application/json and payload:
{
    "node": "node-b5398330-6675-4fdc-8866-d00ab3b625ab",
    "item-id": "item-0b7567f3-8e0d-491a-8e20-a17b11e5fd29"
}

2020-01-02 19:51:42 | from localhost for action retrieve-item got result code 200 and payload
{
    "title": "Retrive PubSub node item",
    "node": "node-b5398330-6675-4fdc-8866-d00ab3b625ab",
    "item-id": "item-0b7567f3-8e0d-491a-8e20-a17b11e5fd29",
    "item": [
        "<item id=\"item-0b7567f3-8e0d-491a-8e20-a17b11e5fd29\"><test>item-0b7567f3-8e0d-491a-8e20-a17b11e5fd29</test></item>"
    ]
}

2020-01-02 19:51:42 | [Mutex] notify: [retrieved:item:item-0b7567f3-8e0d-491a-8e20-a17b11e5fd29:payload-matches:true:localhost]

2020-01-02 19:51:42 | [Mutex] received everything.

2020-01-02 19:51:42 | [Mutex] isItemNotified: retrieved:item:item-0b7567f3-8e0d-491a-8e20-a17b11e5fd29:payload-matches:true:localhost :: true

retrieveUserSubscriptions 0.051s
2020-01-02 19:51:42 |

2020-01-02 19:51:42 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-01-02 19:51:42 | ------------------------------------

2020-01-02 19:51:42 | on localhost executing action retrieve-user-subscriptions with content type application/json and payload:
{
    "jid": "admin@localhost"
}

2020-01-02 19:51:42 | from localhost for action retrieve-user-subscriptions got result code 200 and payload
{
    "nodes": [
        "node-9c99fd0b-3f9f-4681-b35c-13e475b31207",
        "node-b5398330-6675-4fdc-8866-d00ab3b625ab"
    ]
}

retrieveUserSubscriptionsWithRegex 0.048s
2020-01-02 19:51:42 |

2020-01-02 19:51:42 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-01-02 19:51:42 | ------------------------------------

2020-01-02 19:51:42 | on localhost executing action retrieve-user-subscriptions with content type application/json and payload:
{
    "jid": "admin@localhost",
    "node-pattern": "(?!node-b5398330-6675-4fdc-8866-d00ab3b625ab)"
}

2020-01-02 19:51:42 | from localhost for action retrieve-user-subscriptions got result code 200 and payload
{
    "nodes": [
       
    ]
}

subscribeNodes 1.011s
2020-01-02 19:51:41 |

2020-01-02 19:51:41 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-01-02 19:51:41 | ------------------------------------

2020-01-02 19:51:41 | on localhost executing action subscribe-node with content type application/json and payload:
{
    "node": "node-b5398330-6675-4fdc-8866-d00ab3b625ab",
    "jids": [
        "admin@localhost"
    ]
}

2020-01-02 19:51:41 | from localhost for action subscribe-node got result code 200 and payload
{
    "Note": "Operation successful"
}

unsubscribeNodes 1.071s
2020-01-02 19:51:42 |

2020-01-02 19:51:42 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-01-02 19:51:42 | ------------------------------------

2020-01-02 19:51:42 | on localhost executing action unsubscribe-node with content type application/json and payload:
{
    "node": "node-b5398330-6675-4fdc-8866-d00ab3b625ab",
    "jids": [
        "admin@localhost"
    ]
}

2020-01-02 19:51:42 | from localhost for action unsubscribe-node got result code 200 and payload
{
    "Note": "Operation successful"
}