twisted.internet.inotify.IN_ACCESS - python examples

Here are the examples of the python api twisted.internet.inotify.IN_ACCESS taken from open source projects. By voting up you can indicate which examples are most useful and appropriate.

1 Examples 7

3 View Complete Implementation : test_inotify.py
Copyright MIT License
Author : wistbean
    def test_access(self):
        """
        Reading from a file in a monitored directory sends an
        C{inotify.IN_ACCESS} event to the callback.
        """
        def operation(path):
            path.setContent(b"foo")
            path.getContent()

        return self._notificationTest(inotify.IN_ACCESS, operation)