1- from checkbox_support .helpers .file_watcher import FileWatcher , InotfiyEvent
1+ from checkbox_support .helpers .file_watcher import FileWatcher , InotifyEvent
22from unittest .mock import MagicMock , patch
33import unittest
44
55
66class TestInotifyEvent (unittest .TestCase ):
77 """
8- Test the InotfiyEvent data class.
8+ Test the InotifyEvent data class.
99 """
1010
1111 def test_inotify_event_creation (self ):
12- event = InotfiyEvent (
12+ event = InotifyEvent (
1313 wd = 1 , event_type = "modify" , cookie = 0 , name = "test_file.txt"
1414 )
1515 self .assertEqual (event .wd , 1 )
@@ -84,7 +84,7 @@ def test_mask2event(self):
8484 self .assertEqual (watcher ._mask2event (0x0000FFFF ), "unknown" )
8585
8686 @patch ("checkbox_support.helpers.file_watcher.os.read" )
87- @patch ("checkbox_support.helpers.file_watcher.InotfiyEvent " )
87+ @patch ("checkbox_support.helpers.file_watcher.InotifyEvent " )
8888 @patch .object (FileWatcher , "libc" )
8989 def test_read_events_single_event (
9090 self , mock_libc , mock_inotify_event , mock_os_read
@@ -108,7 +108,7 @@ def test_read_events_single_event(
108108 self .assertEqual (events [0 ], mock_event_instance )
109109
110110 @patch ("checkbox_support.helpers.file_watcher.os.read" )
111- @patch ("checkbox_support.helpers.file_watcher.InotfiyEvent " )
111+ @patch ("checkbox_support.helpers.file_watcher.InotifyEvent " )
112112 @patch .object (FileWatcher , "libc" )
113113 def test_read_events_multiple_events (
114114 self , mock_libc , mock_inotify_event , mock_os_read
0 commit comments