Skip to content

Commit

Permalink
Add Test to ReSetImage
Browse files Browse the repository at this point in the history
  • Loading branch information
ricaun committed Dec 8, 2023
1 parent 393ae44 commit 98eabbd
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 1 deletion.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
- `SetLargeImage` always set small image when `ico`.
### Updated
- Update `SetLargeImage` to change small image when `BitmapFrame`.
### Tests
- Add Test to `ReSetImage` when `ico`.

## [0.6.0] / 2023-11-19 - 2023-11-29
### Features
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ public void SetLargeImage_Should_SetImage()
}

[Test]
public void SetLargeImage_Should_NotSetImage()
public void SetLargeImage_Should_ReSetImage()
{
var image = Base64Image;
var largeImage = ComponentImage;
Expand All @@ -90,6 +90,22 @@ public void SetLargeImage_Should_NotSetImage()
var lastImageSource = pushButton.Image;
pushButton.SetLargeImage(largeImage);

Assert.AreNotEqual(lastImageSource, pushButton.Image);

Assert.AreEqual(16, pushButton.Image.Width);
Assert.AreEqual(32, pushButton.LargeImage.Width);
}

[Test]
public void SetLargeImage_Should_NotSetImage()
{
var image = ComponentImage;
var largeImage = Base64Image;
pushButton.SetImage(image);

var lastImageSource = pushButton.Image;
pushButton.SetLargeImage(largeImage);

Assert.AreEqual(lastImageSource, pushButton.Image);
}

Expand Down

0 comments on commit 98eabbd

Please sign in to comment.