Skip to content

Commit

Permalink
Fix some more tests.
Browse files Browse the repository at this point in the history
  • Loading branch information
JeremyKuhne committed Jul 17, 2020
1 parent 8ddbe8c commit 7a8b5da
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -647,7 +647,7 @@ public static IEnumerable<object[]> DrawBorder_OutOfRange_TestData()
{
using var image = new Bitmap(10, 10);
using Graphics graphics = Graphics.FromImage(image);
Assert.Throws<OverflowException>(() => ControlPaint.DrawBorder(graphics, bounds, leftColor, leftWidth, leftStyle, topColor, topWidth, topStyle, rightColor, rightWidth, rightStyle, bottomColor, bottomWidth, bottomStyle));
Assert.Throws<ArgumentOutOfRangeException>(() => ControlPaint.DrawBorder(graphics, bounds, leftColor, leftWidth, leftStyle, topColor, topWidth, topStyle, rightColor, rightWidth, rightStyle, bottomColor, bottomWidth, bottomStyle));
}

[WinFormsTheory]
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Licensed to the .NET Foundation under one or more agreements.
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.

Expand Down Expand Up @@ -2274,10 +2274,10 @@ public void UpDownBase_OnPaint_InvokeWithHandle_CallsPaint(Size size, bool enabl
}

[WinFormsFact]
public void UpDownBase_OnPaint_NullE_ThrowsNullReferenceException()
public void UpDownBase_OnPaint_NullE_ThrowsArgumentNullException()
{
using var control = new SubUpDownBase();
Assert.Throws<NullReferenceException>(() => control.OnPaint(null));
Assert.Throws<ArgumentNullException>(() => control.OnPaint(null));
}

public static IEnumerable<object[]> OnTextBoxKeyDown_TestData()
Expand Down

0 comments on commit 7a8b5da

Please sign in to comment.