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

Tests using png("/dev/null") fail with bitmapType quartz #94

Open
ressy opened this issue Dec 22, 2022 · 0 comments
Open

Tests using png("/dev/null") fail with bitmapType quartz #94

ressy opened this issue Dec 22, 2022 · 0 comments
Labels
Milestone

Comments

@ressy
Copy link
Member

ressy commented Dec 22, 2022

I have some tests for plotting functions that use the equivalent of:

png("/dev/null")
doSomething()
dev.off()

...but on Mac OS this fails with:

Error in dev.off() : 
  QuartzBitmap_Output - unable to open file '/dev/null'

Using cairo (with options(bitmapType = "cairo") or png(..., type = "cairo")), like I see on Linux as the default, does fine. Alternatively a temporary file might be the better way to go. That would also test that the plotting doesn't fail with a platform's default bitmap device. There's already within_tmpdir in the test helpers that could be useful.

@ressy ressy added the bug label Dec 22, 2022
@ressy ressy added this to the Version 0.5.0 milestone Dec 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant