{"id":17774582,"url":"https://github.com/mickeyl/mockstreams","last_synced_at":"2025-04-01T15:32:16.523Z","repository":{"id":185959835,"uuid":"620848228","full_name":"mickeyl/MockStreams","owner":"mickeyl","description":"Mocking Streams in Swift","archived":false,"fork":false,"pushed_at":"2023-03-29T13:49:30.000Z","size":3,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-07T09:45:35.218Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Swift","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mickeyl.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2023-03-29T13:45:44.000Z","updated_at":"2023-03-29T13:48:43.000Z","dependencies_parsed_at":null,"dependency_job_id":"eb0be76d-d2db-4f5f-90ce-32bc08ad777a","html_url":"https://github.com/mickeyl/MockStreams","commit_stats":null,"previous_names":["mickeyl/mockstreams"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mickeyl%2FMockStreams","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mickeyl%2FMockStreams/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mickeyl%2FMockStreams/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mickeyl%2FMockStreams/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mickeyl","download_url":"https://codeload.github.com/mickeyl/MockStreams/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246662495,"owners_count":20813753,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-26T21:51:21.769Z","updated_at":"2025-04-01T15:32:16.493Z","avatar_url":"https://github.com/mickeyl.png","language":"Swift","readme":"# MockStreams\n\n## Mocking streams in Swift.\n\nThis library contains implementations of a pair of `Stream` subclasses intended for helping with unit testing\ncode that uses `Foundation`'s `Stream` instances.\n\n## How to use.\n\nFirst, create an instance of the `MockInputStream`:\n\n```swift\nlet inputStream = MockInputStream()\n```\n\nThen, create an instance of the `MockOutputStream` with the corresponding `MockInputStream` and\na dictionary of request/response pairs:\n\n```swift\n\nlet dict: [String: String] = [\n    \"FOO\": \"BAR\"\n]\n\nlet outputStream = MockOutputStream(inputStream: inputStream, stringDict: dict)\n```\n\nNow, whenever you output something via the output stream, it gets forwarded as\nan input to the corresponding input stream. ","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmickeyl%2Fmockstreams","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmickeyl%2Fmockstreams","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmickeyl%2Fmockstreams/lists"}