-
Notifications
You must be signed in to change notification settings - Fork 24
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
No Header Is Written When Exception Occurs While Writing Inside a Block #5
Comments
I'll work on this issue, but I don't think I have permissions to assign it to myself. |
I committed changes to address this issue on my fork: https://github.com/jamestunnell/wavefile You can pull in the changes if you think they take care of the issue (tests are there as well). |
The exact commit is jamestunnell@8e75345814 |
Thanks for the quick response! Took a look at the commit. Thanks for the well documented and easy to read tests. Only comment is around the What it ultimately seems to be testing is that if the file hasn't been closed yet, you won't be able to read data out of it. It could possibly be simplified by removing the begin/rescue and
|
Yeah, I guess that test is a bit pointless. Not hard to take it out though! |
Awesome, thanks! I've merged in your commits, so closing the issue. |
For example:
When this is run, the
error.wav
will exist on disk, but will not be playable because theWriter
was never closed.Adding an
ensure
clause to theblock_given?
section ofWriter.new
should resolve this.The text was updated successfully, but these errors were encountered: