Namespace: DeltaEngine.Content.Disk.Tests
Assembly: DeltaEngine.Content.Disk.Tests (in DeltaEngine.Content.Disk.Tests.dll) Version: 1.1.1.0 (1.1.1)
Assembly: DeltaEngine.Content.Disk.Tests (in DeltaEngine.Content.Disk.Tests.dll) Version: 1.1.1.0 (1.1.1)
Syntax
Examples
[Test] public void LoadingContentDataFromBinaryDataWillLoadItFromName() { var content = new ImageAnimation(new[] { ContentLoader.Load<Image>("DeltaEngineLogo") }, 1); var data = BinaryDataExtensions.SaveDataIntoMemoryStream(content); Assert.AreEqual(63, data.Length); var loadedContent = BinaryDataExtensions.LoadDataWithKnownTypeFromMemoryStream<ImageAnimation>(data); Assert.AreEqual(content.Name, loadedContent.Name); Assert.AreEqual(content.Frames.Length, loadedContent.Frames.Length); Assert.AreEqual(content.Frames[0], loadedContent.Frames[0]); }
See Also