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

Test duration: 9.007s

Passed Tests
tigase.tests.pubsub.TestRestApiUsingJSON
configureNodes 1.085s
2020-06-24 23:50:32 |

2020-06-24 23:50:32 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-06-24 23:50:32 | ------------------------------------

2020-06-24 23:50:32 | [Mutex] waiting for: [configured:node:node-b61a4e72-10a8-4dfc-9efa-d1a6f0675ff9:node-f94ae9b9-562b-4db6-a1f3-c9fc4b807c52]

2020-06-24 23:50:32 | [Mutex] received everything.

2020-06-24 23:50:32 | [Mutex] isItemNotified: configured:node:node-b61a4e72-10a8-4dfc-9efa-d1a6f0675ff9:node-f94ae9b9-562b-4db6-a1f3-c9fc4b807c52 :: true

2020-06-24 23:50:33 | [Mutex] waiting for: [received:nodes:b1f9d554-a485-41a3-be2e-e2cf69415c6a:localhost]

2020-06-24 23:50:33 | [Mutex] received everything.

2020-06-24 23:50:33 | [Mutex] isItemNotified: received:node:b1f9d554-a485-41a3-be2e-e2cf69415c6a:localhost:node-b61a4e72-10a8-4dfc-9efa-d1a6f0675ff9:Node b61a4e72-10a8-4dfc-9efa-d1a6f0675ff9 :: true

2020-06-24 23:50:33 | [Mutex] waiting for: [received:nodes:20f892c7-54e6-4cca-a609-55c259661d2b:localhost]

2020-06-24 23:50:33 | [Mutex] received everything.

2020-06-24 23:50:33 | [Mutex] isItemNotified: received:node:20f892c7-54e6-4cca-a609-55c259661d2b:localhost:node-b61a4e72-10a8-4dfc-9efa-d1a6f0675ff9:Node b61a4e72-10a8-4dfc-9efa-d1a6f0675ff9 :: false

createNodes 1.725s
2020-06-24 23:50:29 |

2020-06-24 23:50:29 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-06-24 23:50:29 | ------------------------------------

2020-06-24 23:50:30 | on localhost executing action create-node with content type application/json and payload:
{
    "owner": "admin@localhost",
    "pubsub#node_type": "leaf",
    "node": "node-b61a4e72-10a8-4dfc-9efa-d1a6f0675ff9",
    "pubsub#title": "Node b61a4e72-10a8-4dfc-9efa-d1a6f0675ff9"
}

2020-06-24 23:50:30 | from localhost for action create-node got result code 200 and payload
{
    "Note": "Operation successful"
}

2020-06-24 23:50:31 | [Mutex] waiting for: [received:nodes:e81d24d6-1a1b-42d7-8b90-d0cef3c3988e:localhost]

2020-06-24 23:50:31 | [Mutex] received everything.

2020-06-24 23:50:31 | [Mutex] isItemNotified: received:node:e81d24d6-1a1b-42d7-8b90-d0cef3c3988e:localhost:node-b61a4e72-10a8-4dfc-9efa-d1a6f0675ff9:Node b61a4e72-10a8-4dfc-9efa-d1a6f0675ff9 :: true

createSubnodes 1.022s
2020-06-24 23:50:31 |

2020-06-24 23:50:31 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-06-24 23:50:31 | ------------------------------------

2020-06-24 23:50:31 | on localhost executing action create-node with content type application/json and payload:
{
    "owner": "admin@localhost",
    "pubsub#node_type": "collection",
    "node": "node-f94ae9b9-562b-4db6-a1f3-c9fc4b807c52",
    "pubsub#title": "Node f94ae9b9-562b-4db6-a1f3-c9fc4b807c52"
}

2020-06-24 23:50:31 | from localhost for action create-node got result code 200 and payload
{
    "Note": "Operation successful"
}

2020-06-24 23:50:32 | [Mutex] waiting for: [received:nodes:3a95b126-2fc4-415a-9867-1ff6abf3a739:localhost]

2020-06-24 23:50:32 | [Mutex] received everything.

2020-06-24 23:50:32 | [Mutex] isItemNotified: received:node:3a95b126-2fc4-415a-9867-1ff6abf3a739:localhost:node-f94ae9b9-562b-4db6-a1f3-c9fc4b807c52:Node f94ae9b9-562b-4db6-a1f3-c9fc4b807c52 :: true

deleteNodes 1.022s
2020-06-24 23:50:36 |

2020-06-24 23:50:36 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-06-24 23:50:36 | ------------------------------------

2020-06-24 23:50:36 | on localhost executing action delete-node with content type application/json and payload:
{
    "node": "node-f94ae9b9-562b-4db6-a1f3-c9fc4b807c52"
}

2020-06-24 23:50:36 | from localhost for action delete-node got result code 200 and payload
{
    "Note": "Operation successful"
}

2020-06-24 23:50:37 | [Mutex] waiting for: [received:nodes:91ec197f-ff4a-4e47-91d5-dc4f0db7ee37:localhost]

2020-06-24 23:50:37 | [Mutex] received everything.

2020-06-24 23:50:37 | [Mutex] isItemNotified: received:node:91ec197f-ff4a-4e47-91d5-dc4f0db7ee37:localhost:node-f94ae9b9-562b-4db6-a1f3-c9fc4b807c52:Node f94ae9b9-562b-4db6-a1f3-c9fc4b807c52 :: false

deleteSubnodes 1.025s
2020-06-24 23:50:35 |

2020-06-24 23:50:35 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-06-24 23:50:35 | ------------------------------------

2020-06-24 23:50:35 | on localhost executing action delete-node with content type application/json and payload:
{
    "node": "node-b61a4e72-10a8-4dfc-9efa-d1a6f0675ff9"
}

2020-06-24 23:50:35 | from localhost for action delete-node got result code 200 and payload
{
    "Note": "Operation successful"
}

2020-06-24 23:50:36 | [Mutex] waiting for: [received:nodes:c92f2049-2f83-4e8e-8550-f9fd9b6797a2:localhost]

2020-06-24 23:50:36 | [Mutex] received everything.

2020-06-24 23:50:36 | [Mutex] isItemNotified: received:node:c92f2049-2f83-4e8e-8550-f9fd9b6797a2:localhost:node-b61a4e72-10a8-4dfc-9efa-d1a6f0675ff9:Node b61a4e72-10a8-4dfc-9efa-d1a6f0675ff9 :: false

2020-06-24 23:50:36 | [Mutex] waiting for: [received:nodes:a4d5ff02-a888-4a05-b79a-ff68747f110e:localhost]

2020-06-24 23:50:36 | [Mutex] received everything.

2020-06-24 23:50:36 | [Mutex] isItemNotified: received:node:a4d5ff02-a888-4a05-b79a-ff68747f110e:localhost:node-b61a4e72-10a8-4dfc-9efa-d1a6f0675ff9:Node b61a4e72-10a8-4dfc-9efa-d1a6f0675ff9 :: false

publishItemsToNodes 0.048s
2020-06-24 23:50:34 |

2020-06-24 23:50:34 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-06-24 23:50:34 | ------------------------------------

2020-06-24 23:50:34 | on localhost executing action publish-item with content type application/json and payload:
{
    "node": "node-b61a4e72-10a8-4dfc-9efa-d1a6f0675ff9",
    "entry": "<test>item-13203345-cee9-46b1-843e-ad5b53c9027b</test>",
    "item-id": "item-13203345-cee9-46b1-843e-ad5b53c9027b"
}

2020-06-24 23:50:34 | from localhost for action publish-item got result code 200 and payload
{
    "Note": "Operation successful",
    "item-id": "item-13203345-cee9-46b1-843e-ad5b53c9027b"
}

2020-06-24 23:50:34 | [Mutex] received everything.

2020-06-24 23:50:34 | [Mutex] isItemNotified: published:item:notifieditem-13203345-cee9-46b1-843e-ad5b53c9027b:admin@localhost :: true

retractItemsFromNodes 0.061s
2020-06-24 23:50:34 |

2020-06-24 23:50:34 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-06-24 23:50:34 | ------------------------------------

2020-06-24 23:50:34 | on localhost executing action delete-item with content type application/json and payload:
{
    "node": "node-b61a4e72-10a8-4dfc-9efa-d1a6f0675ff9",
    "item-id": "item-13203345-cee9-46b1-843e-ad5b53c9027b"
}

2020-06-24 23:50:34 | from localhost for action delete-item got result code 200 and payload
{
    "Note": "Operation successful",
    "item-id": "item-13203345-cee9-46b1-843e-ad5b53c9027b"
}

2020-06-24 23:50:34 | [Mutex] received everything.

2020-06-24 23:50:34 | [Mutex] isItemNotified: retracted:item:notifieditem-13203345-cee9-46b1-843e-ad5b53c9027b:admin@localhost :: true

retrieveItemsFromNodes 0.062s
2020-06-24 23:50:34 |

2020-06-24 23:50:34 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-06-24 23:50:34 | ------------------------------------

2020-06-24 23:50:34 | on localhost executing action retrieve-item with content type application/json and payload:
{
    "node": "node-b61a4e72-10a8-4dfc-9efa-d1a6f0675ff9",
    "item-id": "item-13203345-cee9-46b1-843e-ad5b53c9027b"
}

2020-06-24 23:50:34 | from localhost for action retrieve-item got result code 200 and payload
{
    "title": "Retrive PubSub node item",
    "node": "node-b61a4e72-10a8-4dfc-9efa-d1a6f0675ff9",
    "item-id": "item-13203345-cee9-46b1-843e-ad5b53c9027b",
    "item": [
        "<item id=\"item-13203345-cee9-46b1-843e-ad5b53c9027b\"><test>item-13203345-cee9-46b1-843e-ad5b53c9027b</test></item>"
    ]
}

2020-06-24 23:50:34 | [Mutex] notify: [retrieved:item:item-13203345-cee9-46b1-843e-ad5b53c9027b:payload-matches:true:localhost]

2020-06-24 23:50:34 | [Mutex] received everything.

2020-06-24 23:50:34 | [Mutex] isItemNotified: retrieved:item:item-13203345-cee9-46b1-843e-ad5b53c9027b:payload-matches:true:localhost :: true

retrieveUserSubscriptions 0.055s
2020-06-24 23:50:34 |

2020-06-24 23:50:34 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-06-24 23:50:34 | ------------------------------------

2020-06-24 23:50:34 | on localhost executing action retrieve-user-subscriptions with content type application/json and payload:
{
    "jid": "admin@localhost"
}

2020-06-24 23:50:34 | from localhost for action retrieve-user-subscriptions got result code 200 and payload
{
    "nodes": [
        "node-b61a4e72-10a8-4dfc-9efa-d1a6f0675ff9",
        "test",
        "node-f94ae9b9-562b-4db6-a1f3-c9fc4b807c52"
    ]
}

retrieveUserSubscriptionsWithRegex 0.048s
2020-06-24 23:50:34 |

2020-06-24 23:50:34 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-06-24 23:50:34 | ------------------------------------

2020-06-24 23:50:34 | on localhost executing action retrieve-user-subscriptions with content type application/json and payload:
{
    "jid": "admin@localhost",
    "node-pattern": "(?!node-b61a4e72-10a8-4dfc-9efa-d1a6f0675ff9)"
}

2020-06-24 23:50:34 | from localhost for action retrieve-user-subscriptions got result code 200 and payload
{
    "nodes": [
       
    ]
}

subscribeNodes 1.013s
2020-06-24 23:50:33 |

2020-06-24 23:50:33 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-06-24 23:50:33 | ------------------------------------

2020-06-24 23:50:33 | on localhost executing action subscribe-node with content type application/json and payload:
{
    "node": "node-b61a4e72-10a8-4dfc-9efa-d1a6f0675ff9",
    "jids": [
        "admin@localhost"
    ]
}

2020-06-24 23:50:33 | from localhost for action subscribe-node got result code 200 and payload
{
    "Note": "Operation successful"
}

unsubscribeNodes 1.078s
2020-06-24 23:50:34 |

2020-06-24 23:50:34 | null / [TestClass name=class tigase.tests.pubsub.TestRestApiUsingJSON]

2020-06-24 23:50:34 | ------------------------------------

2020-06-24 23:50:34 | on localhost executing action unsubscribe-node with content type application/json and payload:
{
    "node": "node-b61a4e72-10a8-4dfc-9efa-d1a6f0675ff9",
    "jids": [
        "admin@localhost"
    ]
}

2020-06-24 23:50:34 | from localhost for action unsubscribe-node got result code 200 and payload
{
    "Note": "Operation successful"
}