//
// Copyright (c) James Jackson-South and contributors.
// Licensed under the Apache License, Version 2.0.
//
namespace ImageSharp.Tests
{
using System;
using Xunit;
///
/// Tests the class.
///
public class ImageTests
{
[Fact]
public void ConstructorByteArray()
{
Assert.Throws(() =>
{
new Image((byte[])null);
});
TestFile file = TestFile.Create(TestImages.Bmp.Car);
Image image = new Image(file.Bytes);
Assert.Equal(600, image.Width);
Assert.Equal(450, image.Height);
}
}
}