Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Request: IO Mockup Features for Fossil Mock #50

Open
dreamer-coding opened this issue Jan 4, 2025 · 0 comments
Open

Feature Request: IO Mockup Features for Fossil Mock #50

dreamer-coding opened this issue Jan 4, 2025 · 0 comments

Comments

@dreamer-coding
Copy link
Collaborator

dreamer-coding commented Jan 4, 2025

Is your feature request related to a problem? Please describe.
Fossil Mock currently lacks comprehensive support for mocking input/output operations, making it difficult to test applications that heavily rely on file, stream, or terminal interactions. I often face challenges when trying to simulate various IO scenarios, such as reading/writing files, handling stdin/stdout, or managing error streams, without affecting the actual environment.

Describe the solution you’d like
I would like Fossil Mock to include robust IO mockup features that allow developers to:
• Mock file operations, such as reading/writing, file creation, deletion, and access permissions, without requiring actual file manipulation.
• Simulate stdin, stdout, and stderr interactions, enabling tests to validate CLI-based input/output handling.
• Mock various error scenarios like file not found, permission denied, or disk full errors.
• Capture and verify terminal output, including formatted text, colors, and special characters.
• Support temporary virtual file systems for testing complex scenarios involving multiple files or directories.

Describe alternatives you’ve considered
• Writing temporary files for testing, but this is not ideal as it depends on the real filesystem and can lead to inconsistent results.
• Using external libraries to mock IO, but these add dependencies and aren’t seamlessly integrated into Fossil Mock.

Additional context
Adding IO mockup features to Fossil Mock would significantly enhance its utility, especially for testing applications that interact with files and terminals. This feature would make it easier to simulate edge cases and ensure robust handling of various IO conditions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant