Changeset 2941
- Timestamp:
- 03/05/10 16:36:58 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Persistence/UnitTests/UseCases.cs
r2939 r2941 18 18 using HeuristicLab.Persistence.Test; 19 19 using System.Drawing; 20 using System.Drawing.Imaging; 20 21 21 22 namespace HeuristicLab.Persistence.UnitTest { … … 646 647 } 647 648 649 [TestMethod] 650 public void BitmapTest() { 651 Icon icon = System.Drawing.SystemIcons.Hand; 652 Bitmap bitmap = icon.ToBitmap(); 653 XmlGenerator.Serialize(bitmap, tempFile); 654 Bitmap newBitmap = (Bitmap)XmlParser.Deserialize(tempFile); 655 656 Assert.AreEqual(bitmap.Size, newBitmap.Size); 657 for(int i=0; i< bitmap.Size.Width; i++) 658 for(int j =0; j< bitmap.Size.Height; j++) 659 Assert.AreEqual(bitmap.GetPixel(i,j),newBitmap.GetPixel(i,j)); 660 } 661 648 662 [ClassInitialize] 649 663 public static void Initialize(TestContext testContext) {
Note: See TracChangeset
for help on using the changeset viewer.