30
30
import logging
31
31
32
32
import chip .clusters as Clusters
33
+ from chip .clusters import Globals
33
34
from chip .clusters .Types import NullValue
34
35
from chip .interaction_model import InteractionModelError , Status
35
36
from matter_testing_support import MatterBaseTest , TestStep , async_test_body , default_matter_test_main
@@ -65,7 +66,7 @@ async def send_edit_atomic_request_begin_command(self,
65
66
endpoint : int = None ,
66
67
expected_status : Status = Status .Success ):
67
68
try :
68
- await self .send_single_cmd (cmd = cluster .Commands .AtomicRequest (requestType = 0 ,
69
+ await self .send_single_cmd (cmd = cluster .Commands .AtomicRequest (requestType = Globals . Enums . AtomicRequestTypeEnum . kBeginWrite ,
69
70
attributeRequests = [
70
71
cluster .Attributes .Presets .attribute_id ],
71
72
timeout = 1800 ),
@@ -81,7 +82,7 @@ async def send_edit_atomic_request_commit_command(self,
81
82
expected_overall_status : Status = Status .Success ,
82
83
expected_preset_status : Status = Status .Success ):
83
84
try :
84
- response = await self .send_single_cmd (cmd = cluster .Commands .AtomicRequest (requestType = 1 ,
85
+ response = await self .send_single_cmd (cmd = cluster .Commands .AtomicRequest (requestType = Globals . Enums . AtomicRequestTypeEnum . kCommitWrite ,
85
86
attributeRequests = [cluster .Attributes .Presets .attribute_id , cluster .Attributes .Schedules .attribute_id ]),
86
87
endpoint = endpoint )
87
88
asserts .assert_equal (expected_status , Status .Success , "We expected we had a valid commit command" )
@@ -100,7 +101,7 @@ async def send_edit_atomic_request_rollback_command(self,
100
101
endpoint : int = None ,
101
102
expected_status : Status = Status .Success ):
102
103
try :
103
- await self .send_single_cmd (cmd = cluster .Commands .AtomicRequest (requestType = 2 ,
104
+ await self .send_single_cmd (cmd = cluster .Commands .AtomicRequest (requestType = Globals . Enums . AtomicRequestTypeEnum . kRollbackWrite ,
104
105
attributeRequests = [cluster .Attributes .Presets .attribute_id , cluster .Attributes .Schedules .attribute_id ]),
105
106
endpoint = endpoint )
106
107
asserts .assert_equal (expected_status , Status .Success )
0 commit comments