'Should omit any stream without a file descriptor.'

def test_return_set_omits_streams_without_file_descriptors(self):

    instance = self.test_instance
    instance.files_preserve = self.test_files.values()
    stream_files = self.stream_files_by_name
    stream_names = stream_files.keys()
    expect_result = self.test_file_descriptors.copy()
    for (pseudo_stream_name, pseudo_stream) in stream_files.items():
        setattr(instance, pseudo_stream_name, StringIO())
        stream_fd = pseudo_stream.fileno()
        expect_result.discard(stream_fd)
    result = instance._get_exclude_file_descriptors()
    self.failUnlessEqual(expect_result, result)
