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

When dataprovider contain binary file contents, the output is unreadable #1427

Closed
coldume opened this issue Sep 5, 2014 · 2 comments
Closed
Assignees
Labels
type/bug Something is broken
Milestone

Comments

@coldume
Copy link

coldume commented Sep 5, 2014

When dataprovider contains binary file contents, if the test fails, the whole contents will
be output to stdout, which make the result unreadable.

In my case:

public function dataProvider()
{
    $contents = file_get_contents('xxx.png');
    return [
        [$contents],
    ];
}

the output is

XXXmethod with data set #0 (// huge amount of binary data...)  Failed asserting xxx

Is there a way to prevent it?

Thanks!

@whatthejeff whatthejeff added the type/bug Something is broken label Sep 17, 2014
@whatthejeff whatthejeff added this to the PHPUnit 4.4 milestone Sep 17, 2014
@whatthejeff whatthejeff self-assigned this Sep 17, 2014
@whatthejeff
Copy link
Contributor

Sorry for the inconvenience, @coldume. This should be fixed when 4.4 is released.

@coldume
Copy link
Author

coldume commented Sep 17, 2014

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/bug Something is broken
Projects
None yet
Development

No branches or pull requests

2 participants