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

Change SchemaDumper.dump default stream to $stdout #50336

Merged
merged 1 commit into from
Dec 14, 2023

Conversation

fatkodima
Copy link
Member

In my gem, I extended SchemaDumper with a small custom logic and when wrote tests for it (fatkodima/online_migrations@39d2f1b#diff-cb07f4a9f75db580d9b7e7bb54c641cb2cab696ef90a9afd64f128fb002a79a7R42-R46) was wondering why capture_io is not working. Turned out, that is because .dump accepts STDOUT (instead of $stdout) as a default output stream.

I changed that method's signature to make it easier to test and also changed 2 test helpers to use that.

@byroot byroot merged commit 970126e into rails:main Dec 14, 2023
4 checks passed
@fatkodima fatkodima deleted the schema_dumper-dump-global-out branch December 14, 2023 16:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants