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

Test duration: 9.110s

Passed Tests
tigase.tests.pubsub.TestRestApiUsingJSON
configureNodes 1.084s
2019-10-13 20:54:28 |

2019-10-13 20:54:28 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-10-13 20:54:28 | ------------------------------------

2019-10-13 20:54:28 | [Mutex] waiting for: [configured:node:node-4fcdf02c-d193-4075-ad5e-c80ec467805d:node-555b732e-e97e-4009-ad2e-ef1339abdb4c]

2019-10-13 20:54:28 | [Mutex] received everything.

2019-10-13 20:54:28 | [Mutex] isItemNotified: configured:node:node-4fcdf02c-d193-4075-ad5e-c80ec467805d:node-555b732e-e97e-4009-ad2e-ef1339abdb4c :: true

2019-10-13 20:54:29 | [Mutex] waiting for: [received:nodes:979d1701-ff68-4235-9e17-83a5feca237e:localhost]

2019-10-13 20:54:29 | [Mutex] received everything.

2019-10-13 20:54:29 | [Mutex] isItemNotified: received:node:979d1701-ff68-4235-9e17-83a5feca237e:localhost:node-4fcdf02c-d193-4075-ad5e-c80ec467805d:Node 4fcdf02c-d193-4075-ad5e-c80ec467805d :: true

2019-10-13 20:54:29 | [Mutex] waiting for: [received:nodes:d4f0731d-5de6-45ae-9655-6bc63ca51de6:localhost]

2019-10-13 20:54:29 | [Mutex] received everything.

2019-10-13 20:54:29 | [Mutex] isItemNotified: received:node:d4f0731d-5de6-45ae-9655-6bc63ca51de6:localhost:node-4fcdf02c-d193-4075-ad5e-c80ec467805d:Node 4fcdf02c-d193-4075-ad5e-c80ec467805d :: false

createNodes 1.668s
2019-10-13 20:54:25 |

2019-10-13 20:54:25 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-10-13 20:54:25 | ------------------------------------

2019-10-13 20:54:26 | on localhost executing action create-node with content type application/json and payload:
{
    "owner": "admin@localhost",
    "pubsub#node_type": "leaf",
    "node": "node-4fcdf02c-d193-4075-ad5e-c80ec467805d",
    "pubsub#title": "Node 4fcdf02c-d193-4075-ad5e-c80ec467805d"
}

2019-10-13 20:54:26 | from localhost for action create-node got result code 200 and payload
{
    "Note": "Operation successful"
}

2019-10-13 20:54:27 | [Mutex] waiting for: [received:nodes:50cde365-02f3-4ea7-9ca5-db38629e81c6:localhost]

2019-10-13 20:54:27 | [Mutex] received everything.

2019-10-13 20:54:27 | [Mutex] isItemNotified: received:node:50cde365-02f3-4ea7-9ca5-db38629e81c6:localhost:node-4fcdf02c-d193-4075-ad5e-c80ec467805d:Node 4fcdf02c-d193-4075-ad5e-c80ec467805d :: true

createSubnodes 1.028s
2019-10-13 20:54:27 |

2019-10-13 20:54:27 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-10-13 20:54:27 | ------------------------------------

2019-10-13 20:54:27 | on localhost executing action create-node with content type application/json and payload:
{
    "owner": "admin@localhost",
    "pubsub#node_type": "collection",
    "node": "node-555b732e-e97e-4009-ad2e-ef1339abdb4c",
    "pubsub#title": "Node 555b732e-e97e-4009-ad2e-ef1339abdb4c"
}

2019-10-13 20:54:27 | from localhost for action create-node got result code 200 and payload
{
    "Note": "Operation successful"
}

2019-10-13 20:54:28 | [Mutex] waiting for: [received:nodes:eca3ea03-59b2-4772-9394-b52e8ed13358:localhost]

2019-10-13 20:54:28 | [Mutex] waiting for: [received:nodes:eca3ea03-59b2-4772-9394-b52e8ed13358:localhost]

2019-10-13 20:54:28 | [Mutex] received everything.

2019-10-13 20:54:28 | [Mutex] isItemNotified: received:node:eca3ea03-59b2-4772-9394-b52e8ed13358:localhost:node-555b732e-e97e-4009-ad2e-ef1339abdb4c:Node 555b732e-e97e-4009-ad2e-ef1339abdb4c :: true

deleteNodes 1.020s
2019-10-13 20:54:32 |

2019-10-13 20:54:32 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-10-13 20:54:32 | ------------------------------------

2019-10-13 20:54:32 | on localhost executing action delete-node with content type application/json and payload:
{
    "node": "node-555b732e-e97e-4009-ad2e-ef1339abdb4c"
}

2019-10-13 20:54:32 | from localhost for action delete-node got result code 200 and payload
{
    "Note": "Operation successful"
}

2019-10-13 20:54:33 | [Mutex] waiting for: [received:nodes:9260be1b-51a3-4054-a17d-f64db402683d:localhost]

2019-10-13 20:54:33 | [Mutex] received everything.

2019-10-13 20:54:33 | [Mutex] isItemNotified: received:node:9260be1b-51a3-4054-a17d-f64db402683d:localhost:node-555b732e-e97e-4009-ad2e-ef1339abdb4c:Node 555b732e-e97e-4009-ad2e-ef1339abdb4c :: false

deleteSubnodes 1.029s
2019-10-13 20:54:31 |

2019-10-13 20:54:31 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-10-13 20:54:31 | ------------------------------------

2019-10-13 20:54:31 | on localhost executing action delete-node with content type application/json and payload:
{
    "node": "node-4fcdf02c-d193-4075-ad5e-c80ec467805d"
}

2019-10-13 20:54:31 | from localhost for action delete-node got result code 200 and payload
{
    "Note": "Operation successful"
}

2019-10-13 20:54:32 | [Mutex] waiting for: [received:nodes:0c2a4ce4-077c-4d01-9677-eb15960a784b:localhost]

2019-10-13 20:54:32 | [Mutex] waiting for: [received:nodes:0c2a4ce4-077c-4d01-9677-eb15960a784b:localhost]

2019-10-13 20:54:32 | [Mutex] received everything.

2019-10-13 20:54:32 | [Mutex] isItemNotified: received:node:0c2a4ce4-077c-4d01-9677-eb15960a784b:localhost:node-4fcdf02c-d193-4075-ad5e-c80ec467805d:Node 4fcdf02c-d193-4075-ad5e-c80ec467805d :: false

2019-10-13 20:54:32 | [Mutex] waiting for: [received:nodes:b961c2ad-3c60-4200-8416-ea491112528b:localhost]

2019-10-13 20:54:32 | [Mutex] received everything.

2019-10-13 20:54:32 | [Mutex] isItemNotified: received:node:b961c2ad-3c60-4200-8416-ea491112528b:localhost:node-4fcdf02c-d193-4075-ad5e-c80ec467805d:Node 4fcdf02c-d193-4075-ad5e-c80ec467805d :: false

publishItemsToNodes 0.052s
2019-10-13 20:54:30 |

2019-10-13 20:54:30 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-10-13 20:54:30 | ------------------------------------

2019-10-13 20:54:30 | on localhost executing action publish-item with content type application/json and payload:
{
    "node": "node-4fcdf02c-d193-4075-ad5e-c80ec467805d",
    "entry": "<test>item-43f0ab4f-9839-49d3-90e9-3002acd4056e</test>",
    "item-id": "item-43f0ab4f-9839-49d3-90e9-3002acd4056e"
}

2019-10-13 20:54:30 | from localhost for action publish-item got result code 200 and payload
{
    "Note": "Operation successful",
    "item-id": "item-43f0ab4f-9839-49d3-90e9-3002acd4056e"
}

2019-10-13 20:54:30 | [Mutex] received everything.

2019-10-13 20:54:30 | [Mutex] isItemNotified: published:item:notifieditem-43f0ab4f-9839-49d3-90e9-3002acd4056e:admin@localhost :: true

retractItemsFromNodes 0.063s
2019-10-13 20:54:30 |

2019-10-13 20:54:30 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-10-13 20:54:30 | ------------------------------------

2019-10-13 20:54:30 | on localhost executing action delete-item with content type application/json and payload:
{
    "node": "node-4fcdf02c-d193-4075-ad5e-c80ec467805d",
    "item-id": "item-43f0ab4f-9839-49d3-90e9-3002acd4056e"
}

2019-10-13 20:54:30 | from localhost for action delete-item got result code 200 and payload
{
    "Note": "Operation successful",
    "item-id": "item-43f0ab4f-9839-49d3-90e9-3002acd4056e"
}

2019-10-13 20:54:30 | [Mutex] received everything.

2019-10-13 20:54:30 | [Mutex] isItemNotified: retracted:item:notifieditem-43f0ab4f-9839-49d3-90e9-3002acd4056e:admin@localhost :: true

retrieveItemsFromNodes 0.062s
2019-10-13 20:54:30 |

2019-10-13 20:54:30 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-10-13 20:54:30 | ------------------------------------

2019-10-13 20:54:30 | on localhost executing action retrieve-item with content type application/json and payload:
{
    "node": "node-4fcdf02c-d193-4075-ad5e-c80ec467805d",
    "item-id": "item-43f0ab4f-9839-49d3-90e9-3002acd4056e"
}

2019-10-13 20:54:30 | from localhost for action retrieve-item got result code 200 and payload
{
    "title": "Retrive PubSub node item",
    "node": "node-4fcdf02c-d193-4075-ad5e-c80ec467805d",
    "item-id": "item-43f0ab4f-9839-49d3-90e9-3002acd4056e",
    "item": [
        "<item id=\"item-43f0ab4f-9839-49d3-90e9-3002acd4056e\"><test>item-43f0ab4f-9839-49d3-90e9-3002acd4056e</test></item>"
    ]
}

2019-10-13 20:54:30 | [Mutex] notify: [retrieved:item:item-43f0ab4f-9839-49d3-90e9-3002acd4056e:payload-matches:true:localhost]

2019-10-13 20:54:30 | [Mutex] received everything.

2019-10-13 20:54:30 | [Mutex] isItemNotified: retrieved:item:item-43f0ab4f-9839-49d3-90e9-3002acd4056e:payload-matches:true:localhost :: true

retrieveUserSubscriptions 0.047s
2019-10-13 20:54:30 |

2019-10-13 20:54:30 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-10-13 20:54:30 | ------------------------------------

2019-10-13 20:54:30 | on localhost executing action retrieve-user-subscriptions with content type application/json and payload:
{
    "jid": "admin@localhost"
}

2019-10-13 20:54:30 | from localhost for action retrieve-user-subscriptions got result code 200 and payload
{
    "nodes": [
        "node-4fcdf02c-d193-4075-ad5e-c80ec467805d",
        "node-555b732e-e97e-4009-ad2e-ef1339abdb4c"
    ]
}

retrieveUserSubscriptionsWithRegex 0.051s
2019-10-13 20:54:30 |

2019-10-13 20:54:30 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-10-13 20:54:30 | ------------------------------------

2019-10-13 20:54:30 | on localhost executing action retrieve-user-subscriptions with content type application/json and payload:
{
    "jid": "admin@localhost",
    "node-pattern": "(?!node-4fcdf02c-d193-4075-ad5e-c80ec467805d)"
}

2019-10-13 20:54:30 | from localhost for action retrieve-user-subscriptions got result code 200 and payload
{
    "nodes": [
       
    ]
}

subscribeNodes 1.015s
2019-10-13 20:54:29 |

2019-10-13 20:54:29 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-10-13 20:54:29 | ------------------------------------

2019-10-13 20:54:29 | on localhost executing action subscribe-node with content type application/json and payload:
{
    "node": "node-4fcdf02c-d193-4075-ad5e-c80ec467805d",
    "jids": [
        "admin@localhost"
    ]
}

2019-10-13 20:54:29 | from localhost for action subscribe-node got result code 200 and payload
{
    "Note": "Operation successful"
}

unsubscribeNodes 1.067s
2019-10-13 20:54:30 |

2019-10-13 20:54:30 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2019-10-13 20:54:30 | ------------------------------------

2019-10-13 20:54:30 | on localhost executing action unsubscribe-node with content type application/json and payload:
{
    "node": "node-4fcdf02c-d193-4075-ad5e-c80ec467805d",
    "jids": [
        "admin@localhost"
    ]
}

2019-10-13 20:54:30 | from localhost for action unsubscribe-node got result code 200 and payload
{
    "Note": "Operation successful"
}