'Set up test fixtures.'

def setUp(self):

    setup_streams_fixtures(self)
    self.test_system_stream = FakeFileDescriptorStringIO()
    self.test_target_stream = FakeFileDescriptorStringIO()
    self.test_null_file = FakeFileDescriptorStringIO()
    def mock_open(path, flag, mode=None):
        if (path == os.devnull):
            result = self.test_null_file.fileno()
        else:
            raise OSError(errno.NOENT, 'No    such    file', path)
        return result
    scaffold.mock('os.open', returns_func=mock_open, tracker=self.mock_tracker)
