File tree Expand file tree Collapse file tree 2 files changed +16
-0
lines changed Expand file tree Collapse file tree 2 files changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -478,6 +478,16 @@ def _do():
478
478
log .info ('Executing: Home now' )
479
479
return _do ()
480
480
481
+ def comment (self , description ):
482
+ def _do ():
483
+ pass
484
+
485
+ def _setup ():
486
+ pass
487
+
488
+ c = Command (do = _do , setup = _setup , description = description )
489
+ self .add_command (c )
490
+
481
491
def add_command (self , command ):
482
492
483
493
if command .description :
Original file line number Diff line number Diff line change @@ -32,6 +32,12 @@ def test_add_container(self):
32
32
}
33
33
self .assertEquals (res , expected )
34
34
35
+ def test_comment (self ):
36
+ self .robot .clear_commands ()
37
+ self .robot .comment ('hello' )
38
+ self .assertEquals (len (self .robot .commands ()), 1 )
39
+ self .assertEquals (self .robot ._commands [0 ].description , 'hello' )
40
+
35
41
def test_home_after_disconnect (self ):
36
42
self .robot .disconnect ()
37
43
self .assertRaises (RuntimeError , self .robot .home )
You can’t perform that action at this time.
0 commit comments