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

Texture2D.FromStream now correctly throws on null arguments #5050

Merged
merged 3 commits into from Aug 2, 2016

Conversation

@Jjagg
Copy link
Contributor

commented Jul 31, 2016

Fixes #5049.

@tomspilman

This comment has been minimized.

Copy link
Member

commented Jul 31, 2016

Thanks @Jjagg . Can you also add in a new unit test for these two cases here:

https://github.com/mono/MonoGame/blob/develop/Test/Framework/Texture2DNonVisualTest.cs

[Test]
public void FromStreamArgumentNullTest()
{
Assert.Throws<ArgumentNullException>(() => Texture2D.FromStream(_game.GraphicsDevice, null));
@tomspilman

This comment has been minimized.

Copy link
Member

commented Aug 2, 2016

Thanks @Jjagg !

@tomspilman tomspilman added this to the 3.6 Release milestone Aug 2, 2016

@tomspilman tomspilman changed the title Throw ArgumentNullException when appropriate in Texture2D.FromStream Texture2D.FromStream now correctly throws on null arguments Aug 2, 2016

@tomspilman tomspilman merged commit cfd02b2 into MonoGame:develop Aug 2, 2016

5 checks passed

Build Mac, iOS, and Linux Finished TeamCity Build MonoGame :: Build Mac : Running
Details
Build Windows, Web, Android, and OUYA Finished TeamCity Build MonoGame :: Build Windows : Running
Details
Package Mac and Linux Finished TeamCity Build MonoGame :: Package Mac and Linux : Running
Details
Package Windows SDK Finished TeamCity Build MonoGame :: Package Windows : Running
Details
Test Windows Finished TeamCity Build MonoGame :: Test Windows : Tests passed: 306
Details

@Jjagg Jjagg deleted the Jjagg:FromStreamNull branch Aug 2, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.