diff --git a/tests/integrational/fixtures/native_sync/objects_v2/channel/get_all_channel.yaml b/tests/integrational/fixtures/native_sync/objects_v2/channel/get_all_channel.yaml deleted file mode 100644 index b106c724..00000000 --- a/tests/integrational/fixtures/native_sync/objects_v2/channel/get_all_channel.yaml +++ /dev/null @@ -1,71 +0,0 @@ -interactions: -- request: - body: '{"name": "Some name", "description": "Some description", "custom": {"key1": - "val1", "key2": "val2"}}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '100' - User-Agent: - - PubNub-Python/4.5.3 - method: PATCH - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/channels/somechannelid?include=custom - response: - body: - string: '{"status":200,"data":{"id":"somechannelid","name":"Some name","description":"Some - description","custom":{"key1":"val1","key2":"val2"},"updated":"2020-09-30T13:58:47.604494Z","eTag":"AdyzhpyljqSqHA"}}' - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Length: - - '199' - Content-Type: - - application/json - Date: - - Wed, 30 Sep 2020 14:00:12 GMT - status: - code: 200 - message: OK -- request: - body: null - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - User-Agent: - - PubNub-Python/4.5.3 - method: GET - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/channels?count=True&include=custom&limit=10&sort=id%3Aasc%2Cupdated%3Adesc - response: - body: - string: '{"status":200,"data":[{"id":"somechannelid","name":"Some name","description":"Some - description","custom":{"key1":"val1","key2":"val2"},"updated":"2020-09-30T13:58:47.604494Z","eTag":"AdyzhpyljqSqHA"}],"totalCount":1,"next":"MQ"}' - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Length: - - '228' - Content-Type: - - application/json - Date: - - Wed, 30 Sep 2020 14:00:12 GMT - status: - code: 200 - message: OK -version: 1 diff --git a/tests/integrational/fixtures/native_sync/objects_v2/channel/get_channel.yaml b/tests/integrational/fixtures/native_sync/objects_v2/channel/get_channel.yaml deleted file mode 100644 index d4c57299..00000000 --- a/tests/integrational/fixtures/native_sync/objects_v2/channel/get_channel.yaml +++ /dev/null @@ -1,35 +0,0 @@ -interactions: -- request: - body: null - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - User-Agent: - - PubNub-Python/4.5.3 - method: GET - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/channels/somechannelid?include=custom - response: - body: - string: '{"status":200,"data":{"id":"somechannelid","name":"Some name","description":"Some - description","custom":{"key1":"val1","key2":"val2"},"updated":"2020-09-30T12:52:14.765159Z","eTag":"AdyzhpyljqSqHA"}}' - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Length: - - '199' - Content-Type: - - application/json - Date: - - Wed, 30 Sep 2020 13:14:48 GMT - status: - code: 200 - message: OK -version: 1 diff --git a/tests/integrational/fixtures/native_sync/objects_v2/channel/remove_channel.yaml b/tests/integrational/fixtures/native_sync/objects_v2/channel/remove_channel.yaml deleted file mode 100644 index 80d57ad5..00000000 --- a/tests/integrational/fixtures/native_sync/objects_v2/channel/remove_channel.yaml +++ /dev/null @@ -1,36 +0,0 @@ -interactions: -- request: - body: null - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '0' - User-Agent: - - PubNub-Python/4.5.3 - method: DELETE - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/channels/somechannelid - response: - body: - string: '{"status":200,"data":null}' - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Length: - - '26' - Content-Type: - - application/json - Date: - - Wed, 30 Sep 2020 13:24:53 GMT - status: - code: 200 - message: OK -version: 1 diff --git a/tests/integrational/fixtures/native_sync/objects_v2/channel/set_channel.yaml b/tests/integrational/fixtures/native_sync/objects_v2/channel/set_channel.yaml deleted file mode 100644 index e6901a64..00000000 --- a/tests/integrational/fixtures/native_sync/objects_v2/channel/set_channel.yaml +++ /dev/null @@ -1,38 +0,0 @@ -interactions: -- request: - body: '{"name": "Some name", "description": "Some description", "custom": {"key1": - "val1", "key2": "val2"}}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '100' - User-Agent: - - PubNub-Python/4.5.3 - method: PATCH - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/channels/somechannelid?include=custom - response: - body: - string: '{"status":200,"data":{"id":"somechannelid","name":"Some name","description":"Some - description","custom":{"key1":"val1","key2":"val2"},"updated":"2020-09-30T12:52:14.765159Z","eTag":"AdyzhpyljqSqHA"}}' - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Length: - - '199' - Content-Type: - - application/json - Date: - - Wed, 30 Sep 2020 12:54:46 GMT - status: - code: 200 - message: OK -version: 1 diff --git a/tests/integrational/fixtures/native_sync/objects_v2/channel_members/get_channel_members.yaml b/tests/integrational/fixtures/native_sync/objects_v2/channel_members/get_channel_members.yaml deleted file mode 100644 index 04712988..00000000 --- a/tests/integrational/fixtures/native_sync/objects_v2/channel_members/get_channel_members.yaml +++ /dev/null @@ -1,80 +0,0 @@ -interactions: -- request: - body: '{"name": "some name with custom", "email": null, "externalId": null, "profileUrl": - null, "custom": {"key3": "val1", "key4": "val2"}}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '132' - User-Agent: - - PubNub-Python/4.5.3 - method: PATCH - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/uuids/someuuid_with_custom - response: - body: - string: '{"status":200,"data":{"id":"someuuid_with_custom","name":"some name - with custom","externalId":null,"profileUrl":null,"email":null,"updated":"2020-10-02T09:37:21.511049Z","eTag":"AefalozsjJrzmAE"}}' - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Length: - - '196' - Content-Type: - - application/json - Date: - - Fri, 02 Oct 2020 11:38:25 GMT - status: - code: 200 - message: OK -- request: - body: null - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - User-Agent: - - PubNub-Python/4.5.3 - method: GET - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/channels/somechannelid/uuids?include=custom%2Cuuid.custom - response: - body: - string: !!binary | - H4sIAAAAAAAAA5yRX0/CMBTFvwq5z2NruxZc34ghhj8+mEwTMYZUKThtt7m1ICx8dzoEwmI0xJem - 596b8+s9raA0wtgSOEHIg5kwAvhTBdYmM+AV1CeUmZb7ggep0PJQae3vHsgvI4tUqIEbTa1SHuRF - Nk+UvC/UsSK1SE7i1ZYm00dlcweVNYYggtoYtRGJUcTDrnuSz2jU6UaTGhOLhRvqvSzvTD7OF4Ob - /qQH2wvscIwpp5iHod9BlDF2bvcYRno4GgXBNXqo7X5ZfbpKzNv0gPoZQ6tut07tf0dSwYdch855 - KRR2Rk7Rb0XqVf/KCvsMY0QbWcm5UNmmfB8WG93rn4e1B7EGqHMBiGGOIp9gRghtfMp6lY7jLPjU - V3blQM8uIheCa90uYLsDAAD//wMAnBDTUmUCAAA= - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Encoding: - - gzip - Content-Type: - - application/json - Date: - - Fri, 02 Oct 2020 11:38:25 GMT - Transfer-Encoding: - - chunked - Vary: - - Accept-Encoding - status: - code: 200 - message: OK -version: 1 diff --git a/tests/integrational/fixtures/native_sync/objects_v2/channel_members/get_channel_members_with_pagination.yaml b/tests/integrational/fixtures/native_sync/objects_v2/channel_members/get_channel_members_with_pagination.yaml deleted file mode 100644 index 8685e0b3..00000000 --- a/tests/integrational/fixtures/native_sync/objects_v2/channel_members/get_channel_members_with_pagination.yaml +++ /dev/null @@ -1,106 +0,0 @@ -interactions: -- request: - body: '{"set": [{"uuid": {"id": "test-fix-118-0"}}, {"uuid": {"id": "test-fix-118-1"}}, - {"uuid": {"id": "test-fix-118-2"}}, {"uuid": {"id": "test-fix-118-3"}}, {"uuid": - {"id": "test-fix-118-4"}}, {"uuid": {"id": "test-fix-118-5"}}, {"uuid": {"id": - "test-fix-118-6"}}, {"uuid": {"id": "test-fix-118-7"}}, {"uuid": {"id": "test-fix-118-8"}}, - {"uuid": {"id": "test-fix-118-9"}}, {"uuid": {"id": "test-fix-118-10"}}, {"uuid": - {"id": "test-fix-118-11"}}, {"uuid": {"id": "test-fix-118-12"}}, {"uuid": {"id": - "test-fix-118-13"}}, {"uuid": {"id": "test-fix-118-14"}}], "delete": []}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '568' - User-Agent: - - PubNub-Python/6.3.0 - method: PATCH - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/channels/somechannelid/uuids - response: - body: - string: '{"status":200,"data":[{"uuid":{"id":"test-fix-118-0"},"updated":"2022-04-21T10:05:14.580127Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-1"},"updated":"2022-04-21T10:05:14.58336Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-10"},"updated":"2022-04-21T10:05:14.605349Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-11"},"updated":"2022-04-21T10:05:14.608585Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-12"},"updated":"2022-04-21T10:05:14.597527Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-13"},"updated":"2022-04-21T10:05:14.576398Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-14"},"updated":"2022-04-21T10:05:14.611731Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-2"},"updated":"2022-04-21T10:05:14.586304Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-3"},"updated":"2022-04-21T10:05:14.58986Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-4"},"updated":"2022-04-21T10:05:14.593492Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-5"},"updated":"2022-04-21T10:05:14.567831Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-6"},"updated":"2022-04-21T10:05:14.572508Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-7"},"updated":"2022-04-21T10:05:14.601774Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-8"},"updated":"2022-04-21T10:05:14.615379Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-9"},"updated":"2022-04-21T10:05:14.618906Z","eTag":"AY39mJKK//C0VA"}],"next":"MTU"}' - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Length: - - '1494' - Content-Type: - - application/json - Date: - - Thu, 21 Apr 2022 10:31:13 GMT - status: - code: 200 - message: OK -- request: - body: null - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - User-Agent: - - PubNub-Python/6.3.0 - method: GET - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/channels/somechannelid/uuids?limit=10 - response: - body: - string: '{"status":200,"data":[{"uuid":{"id":"test-fix-118-0"},"updated":"2022-04-21T10:05:14.580127Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-1"},"updated":"2022-04-21T10:05:14.58336Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-10"},"updated":"2022-04-21T10:05:14.605349Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-11"},"updated":"2022-04-21T10:05:14.608585Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-12"},"updated":"2022-04-21T10:05:14.597527Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-13"},"updated":"2022-04-21T10:05:14.576398Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-14"},"updated":"2022-04-21T10:05:14.611731Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-2"},"updated":"2022-04-21T10:05:14.586304Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-3"},"updated":"2022-04-21T10:05:14.58986Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-4"},"updated":"2022-04-21T10:05:14.593492Z","eTag":"AY39mJKK//C0VA"}],"next":"MTA"}' - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Length: - - '1009' - Content-Type: - - application/json - Date: - - Thu, 21 Apr 2022 10:31:13 GMT - status: - code: 200 - message: OK -- request: - body: null - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - User-Agent: - - PubNub-Python/6.3.0 - method: GET - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/channels/somechannelid/uuids?limit=10&start=MTA - response: - body: - string: '{"status":200,"data":[{"uuid":{"id":"test-fix-118-5"},"updated":"2022-04-21T10:05:14.567831Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-6"},"updated":"2022-04-21T10:05:14.572508Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-7"},"updated":"2022-04-21T10:05:14.601774Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-8"},"updated":"2022-04-21T10:05:14.615379Z","eTag":"AY39mJKK//C0VA"},{"uuid":{"id":"test-fix-118-9"},"updated":"2022-04-21T10:05:14.618906Z","eTag":"AY39mJKK//C0VA"}],"next":"MTU","prev":"MTA"}' - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Length: - - '534' - Content-Type: - - application/json - Date: - - Thu, 21 Apr 2022 10:31:13 GMT - status: - code: 200 - message: OK -version: 1 diff --git a/tests/integrational/fixtures/native_sync/objects_v2/channel_members/manage_channel_members.yaml b/tests/integrational/fixtures/native_sync/objects_v2/channel_members/manage_channel_members.yaml deleted file mode 100644 index f1324ce8..00000000 --- a/tests/integrational/fixtures/native_sync/objects_v2/channel_members/manage_channel_members.yaml +++ /dev/null @@ -1,44 +0,0 @@ -interactions: -- request: - body: '{"set": [{"uuid": {"id": "someuuid"}}], "delete": [{"uuid": {"id": "someuuid_with_custom"}}]}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '93' - User-Agent: - - PubNub-Python/4.5.3 - method: PATCH - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/channels/somechannelid/uuids?include=custom%2Cuuid.custom - response: - body: - string: !!binary | - H4sIAAAAAAAAA4xPTQuCQBT8K/HOWs81jd2bRIR9HIQKMjpsuYmwq6K7EUj/vVUqOnZ5vJk3zLzp - oNVcmxYYQXQg45oDO3VgTJEB66Cf0FZKDIQDJVfizYyG3QHx0KIpuYyttDRSOlA31a2QYt/IDyMU - L77galpdqQ8ytQ0VfQxBgq6HLpIdUubP7EvjYErDGU37mB3PrSi63BNdb+o8Xi7SCJ5/2XlTRgJG - /DGG1A+8X7ujT9VqvZ5M5niwdmdb0Rayl20CzxcAAAD//wMAlqSSoB4BAAA= - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Encoding: - - gzip - Content-Type: - - application/json - Date: - - Fri, 02 Oct 2020 14:26:35 GMT - Transfer-Encoding: - - chunked - Vary: - - Accept-Encoding - status: - code: 200 - message: OK -version: 1 diff --git a/tests/integrational/fixtures/native_sync/objects_v2/channel_members/remove_channel_members.yaml b/tests/integrational/fixtures/native_sync/objects_v2/channel_members/remove_channel_members.yaml deleted file mode 100644 index 7c14d5e7..00000000 --- a/tests/integrational/fixtures/native_sync/objects_v2/channel_members/remove_channel_members.yaml +++ /dev/null @@ -1,45 +0,0 @@ -interactions: -- request: - body: '{"set": [], "delete": [{"uuid": {"id": "someuuid"}}]}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '53' - User-Agent: - - PubNub-Python/4.5.3 - method: PATCH - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/channels/somechannelid/uuids?include=custom%2Cuuid.custom - response: - body: - string: !!binary | - H4sIAAAAAAAAA4yQQU/DMAyF/0rlczcSrwWa2w4chtgBqVxAaDIsg7Kk2ZqEslX77zhiTOzGJfLz - c95neQAfKEQPCoXIYUmBQD0NEGOzBDVAesE7q1Nj0TfhffEafXAWcmjJ6qObpTpLdnay9VfQXUtm - xhFtNCaHTedWjdEPnfntaEvNSRx/MnWtdxNO/iQjOYhV8aMQDjnEDW+p014oUIykGAmsRaUmVwrl - uJRSFNVj4tf0xkNTvSLj9v7jttvb6U1KOAOVZ6DLf4BKqUQ1RlkiFn9BL7u+vavdxdZex55Bz3wi - PgJb83s4fAMAAP//AwCchNwWagEAAA== - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Encoding: - - gzip - Content-Type: - - application/json - Date: - - Fri, 02 Oct 2020 11:59:19 GMT - Transfer-Encoding: - - chunked - Vary: - - Accept-Encoding - status: - code: 200 - message: OK -version: 1 diff --git a/tests/integrational/fixtures/native_sync/objects_v2/channel_members/set_channel_members.yaml b/tests/integrational/fixtures/native_sync/objects_v2/channel_members/set_channel_members.yaml deleted file mode 100644 index bb689a4d..00000000 --- a/tests/integrational/fixtures/native_sync/objects_v2/channel_members/set_channel_members.yaml +++ /dev/null @@ -1,118 +0,0 @@ -interactions: -- request: - body: '{"name": "some name", "email": null, "externalId": null, "profileUrl": - null, "custom": null}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '92' - User-Agent: - - PubNub-Python/4.5.3 - method: PATCH - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/uuids/someuuid - response: - body: - string: '{"status":200,"data":{"id":"someuuid","name":"some name","externalId":null,"profileUrl":null,"email":null,"updated":"2020-10-02T09:37:20.549679Z","eTag":"AbvQtpLpgIGEZA"}}' - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Length: - - '171' - Content-Type: - - application/json - Date: - - Fri, 02 Oct 2020 11:28:59 GMT - status: - code: 200 - message: OK -- request: - body: '{"name": "some name with custom", "email": null, "externalId": null, "profileUrl": - null, "custom": {"key3": "val1", "key4": "val2"}}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '132' - User-Agent: - - PubNub-Python/4.5.3 - method: PATCH - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/uuids/someuuid_with_custom - response: - body: - string: '{"status":200,"data":{"id":"someuuid_with_custom","name":"some name - with custom","externalId":null,"profileUrl":null,"email":null,"updated":"2020-10-02T09:37:21.511049Z","eTag":"AefalozsjJrzmAE"}}' - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Length: - - '196' - Content-Type: - - application/json - Date: - - Fri, 02 Oct 2020 11:29:00 GMT - status: - code: 200 - message: OK -- request: - body: '{"set": [{"uuid": {"id": "someuuid"}}, {"uuid": {"id": "someuuid_with_custom"}, - "custom": {"key5": "val1", "key6": "val2"}}], "delete": []}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '139' - User-Agent: - - PubNub-Python/4.5.3 - method: PATCH - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/channels/somechannelid/uuids?include=custom%2Cuuid.custom - response: - body: - string: !!binary | - H4sIAAAAAAAAA5yRX0/CMBTFvwq5z2NruxZc34ghhj8+mEwTMYZUKThtt7m1ICx8dzoEwmI0xJem - 596b8+s9raA0wtgSOEHIg5kwAvhTBdYmM+AV1CeUmZb7ggep0PJQae3vHsgvI4tUqIEbTa1SHuRF - Nk+UvC/UsSK1SE7i1ZYm00dlcweVNYYggtoYtRGJUcTDrnuSz2jU6UaTGhOLhRvqvSzvTD7OF4Ob - /qQH2wvscIwpp5iHod9BlDF2bvcYRno4GgXBNXqo7X5ZfbpKzNv0gPoZQ6tut07tf0dSwYdch855 - KRR2Rk7Rb0XqVf/KCvsMY0QbWcm5UNmmfB8WG93rn4e1B7EGqHMBiGGOIp9gRghtfMp6lY7jLPjU - V3blQM8uIheCa90uYLsDAAD//wMAnBDTUmUCAAA= - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Encoding: - - gzip - Content-Type: - - application/json - Date: - - Fri, 02 Oct 2020 11:29:01 GMT - Transfer-Encoding: - - chunked - Vary: - - Accept-Encoding - status: - code: 200 - message: OK -version: 1 diff --git a/tests/integrational/fixtures/native_sync/objects_v2/memberships/get_memberships.yaml b/tests/integrational/fixtures/native_sync/objects_v2/memberships/get_memberships.yaml deleted file mode 100644 index 8431da2f..00000000 --- a/tests/integrational/fixtures/native_sync/objects_v2/memberships/get_memberships.yaml +++ /dev/null @@ -1,115 +0,0 @@ -interactions: -- request: - body: '{"name": "some name", "description": null, "custom": null}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '58' - User-Agent: - - PubNub-Python/4.5.3 - method: PATCH - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/channels/somechannel - response: - body: - string: '{"status":200,"data":{"id":"somechannel","name":"some name","description":null,"updated":"2020-10-02T16:42:52.805737Z","eTag":"Ac7cyYSP3pe7Kg"}}' - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Length: - - '144' - Content-Type: - - application/json - Date: - - Fri, 02 Oct 2020 17:38:21 GMT - status: - code: 200 - message: OK -- request: - body: '{"name": "some name with custom", "description": null, "custom": {"key3": - "val1", "key4": "val2"}}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '98' - User-Agent: - - PubNub-Python/4.5.3 - method: PATCH - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/channels/somechannel_with_custom - response: - body: - string: '{"status":200,"data":{"id":"somechannel_with_custom","name":"some name - with custom","description":null,"updated":"2020-10-02T16:42:53.762086Z","eTag":"AcK6vsPkgvuhcA"}}' - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Length: - - '168' - Content-Type: - - application/json - Date: - - Fri, 02 Oct 2020 17:38:22 GMT - status: - code: 200 - message: OK -- request: - body: null - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - User-Agent: - - PubNub-Python/4.5.3 - method: GET - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/uuids/someuuid/channels?include=custom%2Cchannel.custom - response: - body: - string: !!binary | - H4sIAAAAAAAAA5xSa0vDMBT9KyOfty7vNPfbGAOxIoJFmCKjdrEr62PaZnMU/7vZS1bUbfgtJzf3 - nJxzb4OqOqpthYBi3EXTqI4QPDUonkVFYTIEDUqnCFBV5uZw10VFlJv9ZWd7dp2mit/TRZ2WBYLC - ZlkXxbaqy/yA7MKRmw0XxRT3CO5hGhIJnIKgno+FYurREZkwStyjQazi9fj+ji2MChL0eSmdICCk - 5yvJuX9MN2Y6vw6Cfn+IHwaO7qRFhw8md2on3DVobtbE9S+jjLg2h+gO0c2vf/0n1sAFYOlJjTlt - 2X4NQj0eXmmeDnEyutQ3ByqAMg9LzQT5t+/JKq1nk73gzzF3NuXOd/lcKKwVCj8Xyn4XmKckxb5s - 7UIgl9XdPFnaWTw4zmSrI1o68qyOAoZB+E5HEaqPdV7Wq+ImLPtvuW9Xoz/TstYdL5yMBEaAukn7 - XItTG/ns8jYftavcOvQFAAD//wMAci33eJgDAAA= - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Encoding: - - gzip - Content-Type: - - application/json - Date: - - Fri, 02 Oct 2020 17:38:22 GMT - Transfer-Encoding: - - chunked - Vary: - - Accept-Encoding - status: - code: 200 - message: OK -version: 1 diff --git a/tests/integrational/fixtures/native_sync/objects_v2/memberships/manage_memberships.yaml b/tests/integrational/fixtures/native_sync/objects_v2/memberships/manage_memberships.yaml deleted file mode 100644 index 0273780d..00000000 --- a/tests/integrational/fixtures/native_sync/objects_v2/memberships/manage_memberships.yaml +++ /dev/null @@ -1,47 +0,0 @@ -interactions: -- request: - body: '{"set": [{"channel": {"id": "somechannel"}}], "delete": [{"channel": {"id": - "somechannel_with_custom"}}]}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '105' - User-Agent: - - PubNub-Python/4.5.3 - method: PATCH - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/uuids/someuuid/channels?include=custom%2Cchannel.custom - response: - body: - string: !!binary | - H4sIAAAAAAAAA5xQTUvDQBD9KzLnNp2dzSbduZUiiEEQLEKUHpZ0rcEkLWajltD/7tRaUJBQvM2b - 2fe1PbTBha4FJsQRrFxwwI89FM+uaXwF3EO5AoZ2U/vTbgSNq/338uJrFqZvi9dyG8pNA9x0VTWC - omvDpj6hbivi/qBFSDhWOEZaqIRjYkPRFE2q0wcR8gu3lkezIi12+d2t3vo0W8P+PLmUTcImjTRZ - rdRPuVzb+jrLJpM53s9EbrCi4FPJo9tAux5e/E4J/81VSmiC6IjokPrPnGg5NoxJlFiM6Vftp2xh - 8/mVjcs5ri/P7R0zGSYdYWK1+UfvrpPxTK+EtWKS7NPYmumA11L+0H8Eudy8w/4TAAD//wMA4eOR - T2oCAAA= - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Encoding: - - gzip - Content-Type: - - application/json - Date: - - Fri, 02 Oct 2020 17:56:57 GMT - Transfer-Encoding: - - chunked - Vary: - - Accept-Encoding - status: - code: 200 - message: OK -version: 1 diff --git a/tests/integrational/fixtures/native_sync/objects_v2/memberships/remove_memberships.yaml b/tests/integrational/fixtures/native_sync/objects_v2/memberships/remove_memberships.yaml deleted file mode 100644 index c44cf585..00000000 --- a/tests/integrational/fixtures/native_sync/objects_v2/memberships/remove_memberships.yaml +++ /dev/null @@ -1,46 +0,0 @@ -interactions: -- request: - body: '{"set": [], "delete": [{"channel": {"id": "somechannel"}}]}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '59' - User-Agent: - - PubNub-Python/4.5.3 - method: PATCH - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/uuids/someuuid/channels?include=custom%2Cchannel.custom - response: - body: - string: !!binary | - H4sIAAAAAAAAA4yRWWvCQBSF/4rMs8vsydw3EaE0LfQhFGwRmcapBrPYZsZUxP/eiUuJ0Grf7jLn - fMy5O1RZbV2FgGLcRXNtNYLXHUqWuihMhmCH0jkCVJW5Oc1830WFzg2CwmWZF5kq+UzXNi2L8yhx - lS3zRr0yW+L1G50RL/MdPXYU7bvIrT3QNP4UU9wjuIdpjBVwAVj2pcKcBi9eZmK98I+G71GsJqM7 - xdMRXowbhzPoiP3Vj3CgAijrY6mYIG2/CVP5fRQNBiP8PPR2V/89q1O7nJ2A5wQODzpN3WnWnZ/1 - rVDYRSj8VihEAqcgWD+QFIey/YkkkpvqabXYuGUybGdy4IgLjrzJCYBhEKHnBISqNudtWxcPcTn4 - yENXj/9Myzlf/vMyEhgB6i8dciXCK5eZ+rzNl/WbxxrtvwEAAP//AwDIvXqatQIAAA== - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Encoding: - - gzip - Content-Type: - - application/json - Date: - - Fri, 02 Oct 2020 17:45:38 GMT - Transfer-Encoding: - - chunked - Vary: - - Accept-Encoding - status: - code: 200 - message: OK -version: 1 diff --git a/tests/integrational/fixtures/native_sync/objects_v2/memberships/set_memberships.yaml b/tests/integrational/fixtures/native_sync/objects_v2/memberships/set_memberships.yaml deleted file mode 100644 index 16a30f31..00000000 --- a/tests/integrational/fixtures/native_sync/objects_v2/memberships/set_memberships.yaml +++ /dev/null @@ -1,118 +0,0 @@ -interactions: -- request: - body: '{"name": "some name", "description": null, "custom": null}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '58' - User-Agent: - - PubNub-Python/4.5.3 - method: PATCH - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/channels/somechannel - response: - body: - string: '{"status":200,"data":{"id":"somechannel","name":"some name","description":null,"updated":"2020-10-02T16:42:52.805737Z","eTag":"Ac7cyYSP3pe7Kg"}}' - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Length: - - '144' - Content-Type: - - application/json - Date: - - Fri, 02 Oct 2020 17:31:20 GMT - status: - code: 200 - message: OK -- request: - body: '{"name": "some name with custom", "description": null, "custom": {"key3": - "val1", "key4": "val2"}}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '98' - User-Agent: - - PubNub-Python/4.5.3 - method: PATCH - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/channels/somechannel_with_custom - response: - body: - string: '{"status":200,"data":{"id":"somechannel_with_custom","name":"some name - with custom","description":null,"updated":"2020-10-02T16:42:53.762086Z","eTag":"AcK6vsPkgvuhcA"}}' - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Length: - - '168' - Content-Type: - - application/json - Date: - - Fri, 02 Oct 2020 17:31:21 GMT - status: - code: 200 - message: OK -- request: - body: '{"set": [{"channel": {"id": "somechannel"}}, {"channel": {"id": "somechannel_with_custom"}, - "custom": {"key5": "val1", "key6": "val2"}}], "delete": []}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '151' - User-Agent: - - PubNub-Python/4.5.3 - method: PATCH - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/uuids/someuuid/channels?include=custom%2Cchannel.custom - response: - body: - string: !!binary | - H4sIAAAAAAAAA5xSa0vDMBT9KyOfty7vNPfbGAOxIoJFmCKjdrEr62PaZnMU/7vZS1bUbfgtJzf3 - nJxzb4OqOqpthYBi3EXTqI4QPDUonkVFYTIEDUqnCFBV5uZw10VFlJv9ZWd7dp2mit/TRZ2WBYLC - ZlkXxbaqy/yA7MKRmw0XxRT3CO5hGhIJnIKgno+FYurREZkwStyjQazi9fj+ji2MChL0eSmdICCk - 5yvJuX9MN2Y6vw6Cfn+IHwaO7qRFhw8md2on3DVobtbE9S+jjLg2h+gO0c2vf/0n1sAFYOlJjTlt - 2X4NQj0eXmmeDnEyutQ3ByqAMg9LzQT5t+/JKq1nk73gzzF3NuXOd/lcKKwVCj8Xyn4XmKckxb5s - 7UIgl9XdPFnaWTw4zmSrI1o68qyOAoZB+E5HEaqPdV7Wq+ImLPtvuW9Xoz/TstYdL5yMBEaAukn7 - XItTG/ns8jYftavcOvQFAAD//wMAci33eJgDAAA= - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Encoding: - - gzip - Content-Type: - - application/json - Date: - - Fri, 02 Oct 2020 17:31:22 GMT - Transfer-Encoding: - - chunked - Vary: - - Accept-Encoding - status: - code: 200 - message: OK -version: 1 diff --git a/tests/integrational/fixtures/native_sync/objects_v2/uuid/get_all_uuid.yaml b/tests/integrational/fixtures/native_sync/objects_v2/uuid/get_all_uuid.yaml deleted file mode 100644 index 74333d79..00000000 --- a/tests/integrational/fixtures/native_sync/objects_v2/uuid/get_all_uuid.yaml +++ /dev/null @@ -1,49 +0,0 @@ -interactions: -- request: - body: null - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - User-Agent: - - PubNub-Python/4.5.3 - method: GET - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/uuids?count=True&include=custom&limit=10&sort=id%3Aasc%2Cupdated%3Adesc - response: - body: - string: !!binary | - H4sIAAAAAAAAA8yVuXLcMAyG34VtljIBELyqpEzvNEnFA4o90do7Xm3GGY/fPdAkTTqlUyGNcFDQ - px8g38x1revtago6dzKjrtWUb2/mcZhiyNHsakrWx8TWh9FtrsNbzNJwxO5DAnMyT/UspjzdluVk - 5HWVl6e6fN7WA5LX+OXleX5c5MvLor6Hdb2Uuzt5refLIlN/PmuGnOvjFlzlun78N9Rv11Ufypv5 - Ib9Ac37WZSuqFv6x0LyfzO2iny5bUXTorMsW+R58QS7EU8yRmL9ule7rd036NAv75w/eSWB1vJ/+ - EnNLiZGG1Uus9yI29cwW08jkpPco8eDEwMXniR05zDuIQ+4co66eKyoxiVdi6BaYOkNnYcmHJsbC - oQBNEIED7CEe0nNkb3vF2Xqeh61IzaY0u+gJOiR3aGLaNGY3gUeiPcBq+07BUgoqseRq2yZ2GD6F - HCBh9YcG1jEOhVVigOj3SJzEO55V0xxId6/ekm2Uqs2gczwDZgjp0MTa1LEwTp6CQ9xB3KRSQ18t - uaRNXQfaVEe1M2X2oD6gfmhi3bh0jHGKAVOOO4h74FglZRv7iHo4tWEba3+z/gcgx3EeRz+cIBWk - yQVtyD1z3Cu54YPCNn2LV6VtzXPUWwwCsWFu9L/EvwEAAP//orOPjUxABZeZsaEBMVGcYmpiamxg - nqibmmZuDIxiYL1smQhM4yYGhomGKcbJqalmRoPaw8BsbGJlYgSMYgsTS3ztj1gdpZL8ksQc5/zS - vBIlK0NDoK+AXgGq9A1xVKoFAAAA//8DADSKwcGmCQAA - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Encoding: - - gzip - Content-Type: - - application/json - Date: - - Tue, 29 Sep 2020 13:30:11 GMT - Transfer-Encoding: - - chunked - Vary: - - Accept-Encoding - status: - code: 200 - message: OK -version: 1 diff --git a/tests/integrational/fixtures/native_sync/objects_v2/uuid/get_uuid.yaml b/tests/integrational/fixtures/native_sync/objects_v2/uuid/get_uuid.yaml deleted file mode 100644 index e16abbe4..00000000 --- a/tests/integrational/fixtures/native_sync/objects_v2/uuid/get_uuid.yaml +++ /dev/null @@ -1,34 +0,0 @@ -interactions: -- request: - body: null - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - User-Agent: - - PubNub-Python/4.5.3 - method: GET - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/uuids/someuuid?include=custom - response: - body: - string: '{"status":200,"data":{"id":"someuuid","name":"Some name","externalId":"1234","profileUrl":"http://example.com","email":"test@example.com","custom":{"key1":"val1","key2":"val2"},"updated":"2020-09-25T14:41:57.579119Z","eTag":"AYTuwrO3kvz6tAE"}}' - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Length: - - '243' - Content-Type: - - application/json - Date: - - Mon, 28 Sep 2020 11:41:35 GMT - status: - code: 200 - message: OK -version: 1 diff --git a/tests/integrational/fixtures/native_sync/objects_v2/uuid/remove_uuid.yaml b/tests/integrational/fixtures/native_sync/objects_v2/uuid/remove_uuid.yaml deleted file mode 100644 index ca789e73..00000000 --- a/tests/integrational/fixtures/native_sync/objects_v2/uuid/remove_uuid.yaml +++ /dev/null @@ -1,36 +0,0 @@ -interactions: -- request: - body: null - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '0' - User-Agent: - - PubNub-Python/4.5.3 - method: DELETE - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/uuids/someuuid - response: - body: - string: '{"status":200,"data":null}' - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Length: - - '26' - Content-Type: - - application/json - Date: - - Mon, 28 Sep 2020 13:16:50 GMT - status: - code: 200 - message: OK -version: 1 diff --git a/tests/integrational/fixtures/native_sync/objects_v2/uuid/set_uuid.yaml b/tests/integrational/fixtures/native_sync/objects_v2/uuid/set_uuid.yaml deleted file mode 100644 index 16791506..00000000 --- a/tests/integrational/fixtures/native_sync/objects_v2/uuid/set_uuid.yaml +++ /dev/null @@ -1,37 +0,0 @@ -interactions: -- request: - body: '{"name": "Some name", "email": "test@example.com", "externalId": "1234", - "profileUrl": "http://example.com", "custom": {"key1": "val1", "key2": "val2"}}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '152' - User-Agent: - - PubNub-Python/4.5.3 - method: PATCH - uri: https://ps.pndsn.com/v2/objects/sub-c-33f55052-190b-11e6-bfbc-02ee2ddab7fe/uuids/someuuid?include=custom - response: - body: - string: '{"status":200,"data":{"id":"someuuid","name":"Some name","externalId":"1234","profileUrl":"http://example.com","email":"test@example.com","custom":{"key1":"val1","key2":"val2"},"updated":"2020-09-25T14:41:57.579119Z","eTag":"AYTuwrO3kvz6tAE"}}' - headers: - Access-Control-Allow-Credentials: - - 'true' - Access-Control-Allow-Origin: - - '*' - Connection: - - keep-alive - Content-Length: - - '243' - Content-Type: - - application/json - Date: - - Mon, 28 Sep 2020 11:29:04 GMT - status: - code: 200 - message: OK -version: 1 diff --git a/tests/integrational/native_sync/objects_v2/test_channel.py b/tests/integrational/native_sync/objects_v2/test_channel.py index 66b83f93..b92f624b 100644 --- a/tests/integrational/native_sync/objects_v2/test_channel.py +++ b/tests/integrational/native_sync/objects_v2/test_channel.py @@ -9,12 +9,12 @@ from pubnub.models.consumer.objects_v2.sort import PNSortKey, PNSortKeyValue from pubnub.pubnub import PubNub from pubnub.structures import Envelope -from tests.helper import pnconf_copy +from tests.helper import pnconf_env_copy from tests.integrational.vcr_helper import pn_vcr def _pubnub(): - config = pnconf_copy() + config = pnconf_env_copy() return PubNub(config) @@ -40,8 +40,8 @@ def test_set_channel_is_endpoint(self): assert isinstance(set_channel, SetChannel) assert isinstance(set_channel, Endpoint) - @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/channel/set_channel.yaml', - filter_query_parameters=['uuid', 'pnsdk']) + @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/channel/set_channel.json', + filter_query_parameters=['uuid', 'pnsdk'], serializer='pn_json') def test_set_channel_happy_path(self): pn = _pubnub() @@ -76,8 +76,8 @@ def test_get_channel_is_endpoint(self): assert isinstance(get_channel, GetChannel) assert isinstance(get_channel, Endpoint) - @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/channel/get_channel.yaml', - filter_query_parameters=['uuid', 'pnsdk']) + @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/channel/get_channel.json', + filter_query_parameters=['uuid', 'pnsdk'], serializer='pn_json') def test_get_channel_happy_path(self): pn = _pubnub() @@ -109,8 +109,8 @@ def test_remove_channel_is_endpoint(self): assert isinstance(remove_channel, RemoveChannel) assert isinstance(remove_channel, Endpoint) - @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/channel/remove_channel.yaml', - filter_query_parameters=['uuid', 'pnsdk']) + @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/channel/remove_channel.json', + filter_query_parameters=['uuid', 'pnsdk'], serializer='pn_json') def test_remove_channel_happy_path(self): pn = _pubnub() @@ -136,8 +136,8 @@ def test_get_all_channel_is_endpoint(self): assert isinstance(get_all_channel, GetAllChannels) assert isinstance(get_all_channel, Endpoint) - @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/channel/get_all_channel.yaml', - filter_query_parameters=['uuid', 'pnsdk']) + @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/channel/get_all_channel.json', + filter_query_parameters=['uuid', 'pnsdk'], serializer='pn_json') def test_get_all_channel_happy_path(self): pn = _pubnub() diff --git a/tests/integrational/native_sync/objects_v2/test_channel_members.py b/tests/integrational/native_sync/objects_v2/test_channel_members.py index b88aa06e..23bc6c87 100644 --- a/tests/integrational/native_sync/objects_v2/test_channel_members.py +++ b/tests/integrational/native_sync/objects_v2/test_channel_members.py @@ -10,12 +10,12 @@ from pubnub.models.consumer.objects_v2.page import PNPage from pubnub.pubnub import PubNub from pubnub.structures import Envelope -from tests.helper import pnconf_copy +from tests.helper import pnconf_env_copy from tests.integrational.vcr_helper import pn_vcr def _pubnub(): - config = pnconf_copy() + config = pnconf_env_copy() return PubNub(config) @@ -33,8 +33,8 @@ def test_set_channel_members_is_endpoint(self): assert isinstance(set_channel_members, SetChannelMembers) assert isinstance(set_channel_members, Endpoint) - @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/channel_members/set_channel_members.yaml', - filter_query_parameters=['uuid', 'pnsdk']) + @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/channel_members/set_channel_members.json', + filter_query_parameters=['uuid', 'pnsdk'], serializer='pn_json') def test_set_channel_members_happy_path(self): pn = _pubnub() @@ -93,8 +93,8 @@ def test_get_channel_members_is_endpoint(self): assert isinstance(get_channel_members, GetChannelMembers) assert isinstance(get_channel_members, Endpoint) - @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/channel_members/get_channel_members.yaml', - filter_query_parameters=['uuid', 'pnsdk']) + @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/channel_members/get_channel_members.json', + filter_query_parameters=['uuid', 'pnsdk'], serializer='pn_json') def test_get_channel_members_happy_path(self): pn = _pubnub() @@ -133,8 +133,8 @@ def test_get_channel_members_happy_path(self): assert len([e for e in data if e['custom'] == custom_2]) != 0 @pn_vcr.use_cassette( - 'tests/integrational/fixtures/native_sync/objects_v2/channel_members/get_channel_members_with_pagination.yaml', - filter_query_parameters=['uuid', 'pnsdk']) + 'tests/integrational/fixtures/native_sync/objects_v2/channel_members/get_channel_members_with_pagination.json', + filter_query_parameters=['uuid', 'pnsdk'], serializer='pn_json') def test_get_channel_members_with_pagination(self): pn = _pubnub() @@ -183,8 +183,8 @@ def test_remove_channel_members_is_endpoint(self): assert isinstance(remove_channel_members, Endpoint) @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/channel_members/' - 'remove_channel_members.yaml', - filter_query_parameters=['uuid', 'pnsdk']) + 'remove_channel_members.json', + filter_query_parameters=['uuid', 'pnsdk'], serializer='pn_json') def test_remove_channel_members_happy_path(self): pn = _pubnub() @@ -220,8 +220,8 @@ def test_manage_channel_members_is_endpoint(self): assert isinstance(manage_channel_members, Endpoint) @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/channel_members/' - 'manage_channel_members.yaml', - filter_query_parameters=['uuid', 'pnsdk']) + 'manage_channel_members.json', + filter_query_parameters=['uuid', 'pnsdk'], serializer='pn_json') def test_manage_channel_members_happy_path(self): pn = _pubnub() diff --git a/tests/integrational/native_sync/objects_v2/test_memberships.py b/tests/integrational/native_sync/objects_v2/test_memberships.py index 786b08ce..54d84839 100644 --- a/tests/integrational/native_sync/objects_v2/test_memberships.py +++ b/tests/integrational/native_sync/objects_v2/test_memberships.py @@ -9,12 +9,12 @@ PNGetMembershipsResult, PNRemoveMembershipsResult, PNManageMembershipsResult from pubnub.pubnub import PubNub from pubnub.structures import Envelope -from tests.helper import pnconf_copy +from tests.helper import pnconf_env_copy from tests.integrational.vcr_helper import pn_vcr def _pubnub(): - config = pnconf_copy() + config = pnconf_env_copy() return PubNub(config) @@ -32,8 +32,8 @@ def test_set_memberships_is_endpoint(self): assert isinstance(set_memberships, SetMemberships) assert isinstance(set_memberships, Endpoint) - @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/memberships/set_memberships.yaml', - filter_query_parameters=['uuid', 'pnsdk']) + @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/memberships/set_memberships.json', + filter_query_parameters=['uuid', 'pnsdk'], serializer='pn_json') def test_set_memberships_happy_path(self): pn = _pubnub() @@ -94,8 +94,8 @@ def test_get_memberships_is_endpoint(self): assert isinstance(get_memberships, GetMemberships) assert isinstance(get_memberships, Endpoint) - @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/memberships/get_memberships.yaml', - filter_query_parameters=['uuid', 'pnsdk']) + @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/memberships/get_memberships.json', + filter_query_parameters=['uuid', 'pnsdk'], serializer='pn_json') def test_get_memberships_happy_path(self): pn = _pubnub() @@ -150,8 +150,8 @@ def test_remove_memberships_is_endpoint(self): assert isinstance(remove_memberships, RemoveMemberships) assert isinstance(remove_memberships, Endpoint) - @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/memberships/remove_memberships.yaml', - filter_query_parameters=['uuid', 'pnsdk']) + @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/memberships/remove_memberships.json', + filter_query_parameters=['uuid', 'pnsdk'], serializer='pn_json') def test_remove_memberships_happy_path(self): pn = _pubnub() @@ -186,8 +186,8 @@ def test_manage_memberships_is_endpoint(self): assert isinstance(manage_memberships, ManageMemberships) assert isinstance(manage_memberships, Endpoint) - @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/memberships/manage_memberships.yaml', - filter_query_parameters=['uuid', 'pnsdk']) + @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/memberships/manage_memberships.json', + filter_query_parameters=['uuid', 'pnsdk'], serializer='pn_json') def test_manage_memberships_happy_path(self): pn = _pubnub() diff --git a/tests/integrational/native_sync/objects_v2/test_uuid.py b/tests/integrational/native_sync/objects_v2/test_uuid.py index 38496f06..1f78f32d 100644 --- a/tests/integrational/native_sync/objects_v2/test_uuid.py +++ b/tests/integrational/native_sync/objects_v2/test_uuid.py @@ -9,7 +9,7 @@ PNRemoveUUIDMetadataResult, PNGetAllUUIDMetadataResult from pubnub.pubnub import PubNub from pubnub.structures import Envelope -from tests.helper import pnconf_copy +from tests.helper import pnconf_env_copy from tests.integrational.vcr_helper import pn_vcr @@ -25,7 +25,7 @@ class TestObjectsV2UUID: } def test_set_uuid_endpoint_available(self): - config = pnconf_copy() + config = pnconf_env_copy() pn = PubNub(config) set_uuid = pn.set_uuid_metadata() assert set_uuid is not None @@ -33,16 +33,16 @@ def test_set_uuid_endpoint_available(self): assert isinstance(set_uuid, Endpoint) def test_set_uuid_is_endpoint(self): - config = pnconf_copy() + config = pnconf_env_copy() pn = PubNub(config) set_uuid = pn.set_uuid_metadata() assert isinstance(set_uuid, SetUuid) assert isinstance(set_uuid, Endpoint) - @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/uuid/set_uuid.yaml', - filter_query_parameters=['uuid', 'pnsdk']) + @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/uuid/set_uuid.json', + filter_query_parameters=['uuid', 'pnsdk'], serializer='pn_json') def test_set_uuid_happy_path(self): - config = pnconf_copy() + config = pnconf_env_copy() pn = PubNub(config) set_uuid_result = pn.set_uuid_metadata() \ @@ -67,7 +67,7 @@ def test_set_uuid_happy_path(self): assert data['custom'] == TestObjectsV2UUID._some_custom def test_get_uuid_endpoint_available(self): - config = pnconf_copy() + config = pnconf_env_copy() pn = PubNub(config) get_uuid = pn.get_uuid_metadata() assert get_uuid is not None @@ -75,16 +75,16 @@ def test_get_uuid_endpoint_available(self): assert isinstance(get_uuid, Endpoint) def test_get_uuid_is_endpoint(self): - config = pnconf_copy() + config = pnconf_env_copy() pn = PubNub(config) get_uuid = pn.get_uuid_metadata() assert isinstance(get_uuid, GetUuid) assert isinstance(get_uuid, Endpoint) - @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/uuid/get_uuid.yaml', - filter_query_parameters=['uuid', 'pnsdk']) + @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/uuid/get_uuid.json', + filter_query_parameters=['uuid', 'pnsdk'], serializer='pn_json') def test_get_uuid_happy_path(self): - config = pnconf_copy() + config = pnconf_env_copy() pn = PubNub(config) get_uuid_result = pn.get_uuid_metadata() \ @@ -104,7 +104,7 @@ def test_get_uuid_happy_path(self): assert data['custom'] == TestObjectsV2UUID._some_custom def test_remove_uuid_endpoint_available(self): - config = pnconf_copy() + config = pnconf_env_copy() pn = PubNub(config) remove_uuid = pn.remove_uuid_metadata() assert remove_uuid is not None @@ -112,16 +112,16 @@ def test_remove_uuid_endpoint_available(self): assert isinstance(remove_uuid, Endpoint) def test_remove_uuid_is_endpoint(self): - config = pnconf_copy() + config = pnconf_env_copy() pn = PubNub(config) remove_uuid = pn.remove_uuid_metadata() assert isinstance(remove_uuid, RemoveUuid) assert isinstance(remove_uuid, Endpoint) - @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/uuid/remove_uuid.yaml', - filter_query_parameters=['uuid', 'pnsdk']) + @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/uuid/remove_uuid.json', + filter_query_parameters=['uuid', 'pnsdk'], serializer='pn_json') def test_remove_uuid_happy_path(self): - config = pnconf_copy() + config = pnconf_env_copy() pn = PubNub(config) remove_uid_result = pn.remove_uuid_metadata() \ @@ -133,7 +133,7 @@ def test_remove_uuid_happy_path(self): assert isinstance(remove_uid_result.status, PNStatus) def test_get_all_uuid_endpoint_available(self): - config = pnconf_copy() + config = pnconf_env_copy() pn = PubNub(config) get_all_uuid = pn.get_all_uuid_metadata() assert get_all_uuid is not None @@ -141,16 +141,16 @@ def test_get_all_uuid_endpoint_available(self): assert isinstance(get_all_uuid, Endpoint) def test_get_all_uuid_is_endpoint(self): - config = pnconf_copy() + config = pnconf_env_copy() pn = PubNub(config) get_all_uuid = pn.get_all_uuid_metadata() assert isinstance(get_all_uuid, GetAllUuid) assert isinstance(get_all_uuid, Endpoint) - @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/uuid/get_all_uuid.yaml', - filter_query_parameters=['uuid', 'pnsdk']) + @pn_vcr.use_cassette('tests/integrational/fixtures/native_sync/objects_v2/uuid/get_all_uuid.json', + filter_query_parameters=['uuid', 'pnsdk'], serializer='pn_json') def test_get_all_uuid_happy_path(self): - config = pnconf_copy() + config = pnconf_env_copy() pn = PubNub(config) get_all_uuid_result = pn.get_all_uuid_metadata() \