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

Test duration: 9.181s

Passed Tests
tigase.tests.pubsub.TestRestApiUsingJSON
configureNodes 1.119s
2019-11-21 03:34:06 |

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

2019-11-21 03:34:06 | ------------------------------------

2019-11-21 03:34:06 | [Mutex] waiting for: [configured:node:node-d8805461-5a79-4110-8d9e-d2f4367cb2e8:node-c68ef3d2-795e-42ea-a09c-42fb376a2d36]

2019-11-21 03:34:07 | [Mutex] received everything.

2019-11-21 03:34:07 | [Mutex] isItemNotified: configured:node:node-d8805461-5a79-4110-8d9e-d2f4367cb2e8:node-c68ef3d2-795e-42ea-a09c-42fb376a2d36 :: true

2019-11-21 03:34:08 | [Mutex] waiting for: [received:nodes:1f3f30cf-5892-451d-89fa-5d3a5f6d3a71:localhost]

2019-11-21 03:34:08 | [Mutex] received everything.

2019-11-21 03:34:08 | [Mutex] isItemNotified: received:node:1f3f30cf-5892-451d-89fa-5d3a5f6d3a71:localhost:node-d8805461-5a79-4110-8d9e-d2f4367cb2e8:Node d8805461-5a79-4110-8d9e-d2f4367cb2e8 :: true

2019-11-21 03:34:08 | [Mutex] waiting for: [received:nodes:3c490295-ce54-4ed8-91ad-aa8e33619fb3:localhost]

2019-11-21 03:34:08 | [Mutex] received everything.

2019-11-21 03:34:08 | [Mutex] isItemNotified: received:node:3c490295-ce54-4ed8-91ad-aa8e33619fb3:localhost:node-d8805461-5a79-4110-8d9e-d2f4367cb2e8:Node d8805461-5a79-4110-8d9e-d2f4367cb2e8 :: false

createNodes 1.808s
2019-11-21 03:34:04 |

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

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

2019-11-21 03:34:04 | on localhost executing action create-node with content type application/json and payload:
{
    "owner": "admin@localhost",
    "pubsub#node_type": "leaf",
    "node": "node-d8805461-5a79-4110-8d9e-d2f4367cb2e8",
    "pubsub#title": "Node d8805461-5a79-4110-8d9e-d2f4367cb2e8"
}

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

2019-11-21 03:34:05 | [Mutex] waiting for: [received:nodes:28e1677a-07a2-4767-96aa-e0c6736c8c21:localhost]

2019-11-21 03:34:05 | [Mutex] received everything.

2019-11-21 03:34:05 | [Mutex] isItemNotified: received:node:28e1677a-07a2-4767-96aa-e0c6736c8c21:localhost:node-d8805461-5a79-4110-8d9e-d2f4367cb2e8:Node d8805461-5a79-4110-8d9e-d2f4367cb2e8 :: true

createSubnodes 1.028s
2019-11-21 03:34:05 |

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

2019-11-21 03:34:05 | ------------------------------------

2019-11-21 03:34:05 | on localhost executing action create-node with content type application/json and payload:
{
    "owner": "admin@localhost",
    "pubsub#node_type": "collection",
    "node": "node-c68ef3d2-795e-42ea-a09c-42fb376a2d36",
    "pubsub#title": "Node c68ef3d2-795e-42ea-a09c-42fb376a2d36"
}

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

2019-11-21 03:34:06 | [Mutex] waiting for: [received:nodes:90a8ac35-0913-4baf-88df-8feda806f286:localhost]

2019-11-21 03:34:06 | [Mutex] waiting for: [received:nodes:90a8ac35-0913-4baf-88df-8feda806f286:localhost]

2019-11-21 03:34:06 | [Mutex] received everything.

2019-11-21 03:34:06 | [Mutex] isItemNotified: received:node:90a8ac35-0913-4baf-88df-8feda806f286:localhost:node-c68ef3d2-795e-42ea-a09c-42fb376a2d36:Node c68ef3d2-795e-42ea-a09c-42fb376a2d36 :: true

deleteNodes 1.026s
2019-11-21 03:34:11 |

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

2019-11-21 03:34:11 | ------------------------------------

2019-11-21 03:34:11 | on localhost executing action delete-node with content type application/json and payload:
{
    "node": "node-c68ef3d2-795e-42ea-a09c-42fb376a2d36"
}

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

2019-11-21 03:34:12 | [Mutex] waiting for: [received:nodes:244db33c-0dd3-4894-8bd2-a54dfeac6759:localhost]

2019-11-21 03:34:12 | [Mutex] received everything.

2019-11-21 03:34:12 | [Mutex] isItemNotified: received:node:244db33c-0dd3-4894-8bd2-a54dfeac6759:localhost:node-c68ef3d2-795e-42ea-a09c-42fb376a2d36:Node c68ef3d2-795e-42ea-a09c-42fb376a2d36 :: false

deleteSubnodes 1.036s
2019-11-21 03:34:10 |

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

2019-11-21 03:34:10 | ------------------------------------

2019-11-21 03:34:10 | on localhost executing action delete-node with content type application/json and payload:
{
    "node": "node-d8805461-5a79-4110-8d9e-d2f4367cb2e8"
}

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

2019-11-21 03:34:11 | [Mutex] waiting for: [received:nodes:d42fa7d3-f325-4a0f-bd2b-7ec2f21b713d:localhost]

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

2019-11-21 03:34:11 | [Mutex] isItemNotified: received:node:d42fa7d3-f325-4a0f-bd2b-7ec2f21b713d:localhost:node-d8805461-5a79-4110-8d9e-d2f4367cb2e8:Node d8805461-5a79-4110-8d9e-d2f4367cb2e8 :: false

2019-11-21 03:34:11 | [Mutex] waiting for: [received:nodes:e640e690-b155-4d33-94a0-b4b1f8ff418a:localhost]

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

2019-11-21 03:34:11 | [Mutex] isItemNotified: received:node:e640e690-b155-4d33-94a0-b4b1f8ff418a:localhost:node-d8805461-5a79-4110-8d9e-d2f4367cb2e8:Node d8805461-5a79-4110-8d9e-d2f4367cb2e8 :: false

publishItemsToNodes 0.046s
2019-11-21 03:34:09 |

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

2019-11-21 03:34:09 | ------------------------------------

2019-11-21 03:34:09 | on localhost executing action publish-item with content type application/json and payload:
{
    "node": "node-d8805461-5a79-4110-8d9e-d2f4367cb2e8",
    "entry": "<test>item-4e6ca7c2-411b-4fb6-ba8b-48764b2fdf83</test>",
    "item-id": "item-4e6ca7c2-411b-4fb6-ba8b-48764b2fdf83"
}

2019-11-21 03:34:09 | from localhost for action publish-item got result code 200 and payload
{
    "Note": "Operation successful",
    "item-id": "item-4e6ca7c2-411b-4fb6-ba8b-48764b2fdf83"
}

2019-11-21 03:34:09 | [Mutex] waiting for: [published:item:notifieditem-4e6ca7c2-411b-4fb6-ba8b-48764b2fdf83:admin@localhost]

2019-11-21 03:34:09 | [Mutex] received everything.

2019-11-21 03:34:09 | [Mutex] isItemNotified: published:item:notifieditem-4e6ca7c2-411b-4fb6-ba8b-48764b2fdf83:admin@localhost :: true

retractItemsFromNodes 0.052s
2019-11-21 03:34:09 |

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

2019-11-21 03:34:09 | ------------------------------------

2019-11-21 03:34:09 | on localhost executing action delete-item with content type application/json and payload:
{
    "node": "node-d8805461-5a79-4110-8d9e-d2f4367cb2e8",
    "item-id": "item-4e6ca7c2-411b-4fb6-ba8b-48764b2fdf83"
}

2019-11-21 03:34:09 | from localhost for action delete-item got result code 200 and payload
{
    "Note": "Operation successful",
    "item-id": "item-4e6ca7c2-411b-4fb6-ba8b-48764b2fdf83"
}

2019-11-21 03:34:09 | [Mutex] received everything.

2019-11-21 03:34:09 | [Mutex] isItemNotified: retracted:item:notifieditem-4e6ca7c2-411b-4fb6-ba8b-48764b2fdf83:admin@localhost :: true

retrieveItemsFromNodes 0.055s
2019-11-21 03:34:09 |

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

2019-11-21 03:34:09 | ------------------------------------

2019-11-21 03:34:09 | on localhost executing action retrieve-item with content type application/json and payload:
{
    "node": "node-d8805461-5a79-4110-8d9e-d2f4367cb2e8",
    "item-id": "item-4e6ca7c2-411b-4fb6-ba8b-48764b2fdf83"
}

2019-11-21 03:34:09 | from localhost for action retrieve-item got result code 200 and payload
{
    "title": "Retrive PubSub node item",
    "node": "node-d8805461-5a79-4110-8d9e-d2f4367cb2e8",
    "item-id": "item-4e6ca7c2-411b-4fb6-ba8b-48764b2fdf83",
    "item": [
        "<item id=\"item-4e6ca7c2-411b-4fb6-ba8b-48764b2fdf83\"><test>item-4e6ca7c2-411b-4fb6-ba8b-48764b2fdf83</test></item>"
    ]
}

2019-11-21 03:34:09 | [Mutex] notify: [retrieved:item:item-4e6ca7c2-411b-4fb6-ba8b-48764b2fdf83:payload-matches:true:localhost]

2019-11-21 03:34:09 | [Mutex] received everything.

2019-11-21 03:34:09 | [Mutex] isItemNotified: retrieved:item:item-4e6ca7c2-411b-4fb6-ba8b-48764b2fdf83:payload-matches:true:localhost :: true

retrieveUserSubscriptions 0.047s
2019-11-21 03:34:09 |

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

2019-11-21 03:34:09 | ------------------------------------

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

2019-11-21 03:34:09 | from localhost for action retrieve-user-subscriptions got result code 200 and payload
{
    "nodes": [
        "node-d8805461-5a79-4110-8d9e-d2f4367cb2e8",
        "node-c68ef3d2-795e-42ea-a09c-42fb376a2d36"
    ]
}

retrieveUserSubscriptionsWithRegex 0.048s
2019-11-21 03:34:09 |

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

2019-11-21 03:34:09 | ------------------------------------

2019-11-21 03:34:09 | on localhost executing action retrieve-user-subscriptions with content type application/json and payload:
{
    "jid": "admin@localhost",
    "node-pattern": "(?!node-d8805461-5a79-4110-8d9e-d2f4367cb2e8)"
}

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

subscribeNodes 1.013s
2019-11-21 03:34:08 |

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

2019-11-21 03:34:08 | ------------------------------------

2019-11-21 03:34:08 | on localhost executing action subscribe-node with content type application/json and payload:
{
    "node": "node-d8805461-5a79-4110-8d9e-d2f4367cb2e8",
    "jids": [
        "admin@localhost"
    ]
}

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

unsubscribeNodes 1.071s
2019-11-21 03:34:09 |

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

2019-11-21 03:34:09 | ------------------------------------

2019-11-21 03:34:09 | on localhost executing action unsubscribe-node with content type application/json and payload:
{
    "node": "node-d8805461-5a79-4110-8d9e-d2f4367cb2e8",
    "jids": [
        "admin@localhost"
    ]
}

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