Quasar/Client.Tests/Core/Compression/JpgCompression.Tests.cs

24 lines
625 B
C#
Raw Normal View History

using System;
using System.Drawing;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using xClient.Core.Compression;
namespace xClient.Tests.Core.Compression
{
[TestClass]
public class JpgCompressionTests
{
[TestMethod, TestCategory("Compression")]
2015-05-14 08:26:28 +00:00
public void CompressionTest()
{
var quality = Int64.MaxValue;
var jpg = new JpgCompression(quality);
var bitmap = new Bitmap(200, 200);
var result = jpg.Compress(bitmap);
Assert.IsNotNull(result);
CollectionAssert.AllItemsAreNotNull(result);
}
}
}