File tree Expand file tree Collapse file tree 3 files changed +51
-4
lines changed Expand file tree Collapse file tree 3 files changed +51
-4
lines changed Original file line number Diff line number Diff line change 1
- { "engineHash" : " 9f6df0d " , "specHash" : " b2f7568" , "version" : " 0.5.1" }
1
+ { "engineHash" : " 9836a44 " , "specHash" : " b2f7568" , "version" : " 0.5.1" }
Original file line number Diff line number Diff line change @@ -13,7 +13,11 @@ This operation is performed by calling function `get_device_pinner_by_id`.
13
13
See the endpoint docs at
14
14
[ API Reference] ( https://developer.box.com/reference/get-device-pinners-id/ ) .
15
15
16
- _ Currently we don't have an example for calling ` get_device_pinner_by_id ` in integration tests_
16
+ <!-- sample get_device_pinners_id -->
17
+
18
+ ``` python
19
+ client.device_pinners.get_device_pinner_by_id(device_pinner_id = device_pinner_id)
20
+ ```
17
21
18
22
### Arguments
19
23
@@ -37,7 +41,11 @@ This operation is performed by calling function `delete_device_pinner_by_id`.
37
41
See the endpoint docs at
38
42
[ API Reference] ( https://developer.box.com/reference/delete-device-pinners-id/ ) .
39
43
40
- _ Currently we don't have an example for calling ` delete_device_pinner_by_id ` in integration tests_
44
+ <!-- sample delete_device_pinners_id -->
45
+
46
+ ``` python
47
+ client.device_pinners.delete_device_pinner_by_id(device_pinner_id = device_pinner_id)
48
+ ```
41
49
42
50
### Arguments
43
51
@@ -64,7 +72,11 @@ This operation is performed by calling function `get_enterprise_device_pinners`.
64
72
See the endpoint docs at
65
73
[ API Reference] ( https://developer.box.com/reference/get-enterprises-id-device-pinners/ ) .
66
74
67
- _ Currently we don't have an example for calling ` get_enterprise_device_pinners ` in integration tests_
75
+ <!-- sample get_enterprises_id_device_pinners -->
76
+
77
+ ``` python
78
+ client.device_pinners.get_enterprise_device_pinners(enterprise_id = enterprise_id, direction = GetEnterpriseDevicePinnersDirection.DESC .value)
79
+ ```
68
80
69
81
### Arguments
70
82
Original file line number Diff line number Diff line change
1
+ import pytest
2
+
3
+ from box_sdk_gen .client import BoxClient
4
+
5
+ from box_sdk_gen .schemas import DevicePinners
6
+
7
+ from box_sdk_gen .managers .device_pinners import GetEnterpriseDevicePinnersDirection
8
+
9
+ from test .commons import get_default_client
10
+
11
+ from box_sdk_gen .internal .utils import get_env_var
12
+
13
+ client : BoxClient = get_default_client ()
14
+
15
+
16
+ def testDevicePinners ():
17
+ enterprise_id : str = get_env_var ('ENTERPRISE_ID' )
18
+ device_pinners : DevicePinners = client .device_pinners .get_enterprise_device_pinners (
19
+ enterprise_id = enterprise_id
20
+ )
21
+ assert len (device_pinners .entries ) >= 0
22
+ device_pinners_in_desc_direction : DevicePinners = (
23
+ client .device_pinners .get_enterprise_device_pinners (
24
+ enterprise_id = enterprise_id ,
25
+ direction = GetEnterpriseDevicePinnersDirection .DESC .value ,
26
+ )
27
+ )
28
+ assert len (device_pinners_in_desc_direction .entries ) >= 0
29
+ device_pinner_id : str = '123456'
30
+ with pytest .raises (Exception ):
31
+ client .device_pinners .get_device_pinner_by_id (device_pinner_id = device_pinner_id )
32
+ with pytest .raises (Exception ):
33
+ client .device_pinners .delete_device_pinner_by_id (
34
+ device_pinner_id = device_pinner_id
35
+ )
You can’t perform that action at this time.
0 commit comments