System\Drawing\BitmapTests.cs (6)
79AssertExtensions.Throws<ArgumentException>(paramName, null, () => new Bitmap(filename));
80AssertExtensions.Throws<ArgumentException>(paramName, null, () => new Bitmap(filename, false));
81AssertExtensions.Throws<ArgumentException>(paramName, null, () => new Bitmap(filename, true));
297AssertExtensions.Throws<ArgumentNullException>("g", null, () => new Bitmap(1, 1, null));
342AssertExtensions.Throws<ArgumentNullException>("original", "image", () => new Bitmap(null, new Size(1, 2)));
343AssertExtensions.Throws<ArgumentNullException>("original", "image", () => new Bitmap(null, 1, 2));
System\Drawing\Imaging\MetafileTests.cs (5)
90AssertExtensions.Throws<ArgumentException>("path", null, () => new Metafile(path));
427AssertExtensions.Throws<ArgumentException>("path", null, () => new Metafile(fileName, referenceHdc));
428AssertExtensions.Throws<ArgumentException>("path", null, () => new Metafile(fileName, referenceHdc, EmfType.EmfOnly));
429AssertExtensions.Throws<ArgumentException>("path", null, () => new Metafile(fileName, referenceHdc, EmfType.EmfOnly, "description"));
858AssertExtensions.Throws<ArgumentException>("path", null, () => Metafile.GetMetafileHeader(fileName));