CHange unit tests from BeOS R4.5 to files generated with fssetter.

This commit is contained in:
2021-04-28 10:51:09 +01:00
parent cba71d8535
commit d62aea0944
7 changed files with 90 additions and 13 deletions

View File

@@ -59,9 +59,9 @@ namespace Aaru.Tests.Filesystems.BeFS
{
TestFile = "beos_r4.5.aif",
MediaType = MediaType.GENERIC_HDD,
Sectors = 1572864,
Sectors = 262144,
SectorSize = 512,
Clusters = 786336,
Clusters = 130976,
ClusterSize = 1024,
VolumeName = "Volume label"
}

View File

@@ -59,9 +59,9 @@ namespace Aaru.Tests.Filesystems.BeFS
{
TestFile = "beos_r4.5.aif",
MediaType = MediaType.GENERIC_HDD,
Sectors = 1572864,
Sectors = 262144,
SectorSize = 512,
Clusters = 785232,
Clusters = 130536,
ClusterSize = 1024,
VolumeName = "Volume label"
},

View File

@@ -4938,7 +4938,7 @@ namespace Aaru.Tests.Filesystems.FAT12
Clusters = 2880,
ClusterSize = 512,
SystemId = "BeOS ",
VolumeName = "VOLUMELABEL",
VolumeName = "VOLUME LABE",
VolumeSerial = "00000000"
},
new FileSystemTest

View File

@@ -688,13 +688,13 @@ namespace Aaru.Tests.Filesystems.FAT16
{
TestFile = "beos_r4.5.aif",
MediaType = MediaType.GENERIC_HDD,
Sectors = 1024000,
Sectors = 262144,
SectorSize = 512,
Bootable = true,
Clusters = 63996,
ClusterSize = 8192,
Clusters = 65268,
ClusterSize = 2048,
SystemId = "BeOS ",
VolumeName = "VOLUMELABEL",
VolumeName = "VOLUME LABE",
VolumeSerial = "00000000"
},
new FileSystemTest

View File

@@ -67,6 +67,19 @@ namespace Aaru.Tests.Filesystems.FAT16
Clusters = 5760,
ClusterSize = 512,
SystemId = "IBM 3.3"
},
new FileSystemTest
{
TestFile = "beos_r4.5_mf2hd.img.lz",
MediaType = MediaType.DOS_35_HD,
Sectors = 2880,
SectorSize = 512,
Bootable = true,
Clusters = 2880,
ClusterSize = 512,
SystemId = "BeOS ",
VolumeName = "VOLUME LABE",
VolumeSerial = "00000000"
}
};
}

View File

@@ -218,13 +218,13 @@ namespace Aaru.Tests.Filesystems.FAT32
{
TestFile = "beos_r4.5.aif",
MediaType = MediaType.GENERIC_HDD,
Sectors = 4194304,
Sectors = 262144,
SectorSize = 512,
Bootable = true,
Clusters = 1048560,
ClusterSize = 2048,
Clusters = 261072,
ClusterSize = 512,
SystemId = "BeOS ",
VolumeName = "VOLUMELABEL",
VolumeName = "VOLUME LABE",
VolumeSerial = "00000000"
},
new FileSystemTest

View File

@@ -0,0 +1,64 @@
// /***************************************************************************
// Aaru Data Preservation Suite
// ----------------------------------------------------------------------------
//
// Filename : FAT16.cs
// Author(s) : Natalia Portillo <claunia@claunia.com>
//
// Component : Aaru unit testing.
//
// --[ License ] --------------------------------------------------------------
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
//
// ----------------------------------------------------------------------------
// Copyright © 2011-2021 Natalia Portillo
// ****************************************************************************/
using System.IO;
using Aaru.CommonTypes;
using Aaru.CommonTypes.Interfaces;
using Aaru.Filesystems;
using NUnit.Framework;
namespace Aaru.Tests.Filesystems.FAT32
{
[TestFixture]
public class Whole : FilesystemTest
{
public Whole() : base("FAT32") {}
public override string DataFolder => Path.Combine(Consts.TEST_FILES_ROOT, "Filesystems", "FAT32");
public override IFilesystem Plugin => new FAT();
public override bool Partitions => false;
public override FileSystemTest[] Tests => new[]
{
new FileSystemTest
{
TestFile = "beos_r4.5_mf2hd.img.lz",
MediaType = MediaType.DOS_35_HD,
Sectors = 2880,
SectorSize = 512,
Bootable = true,
Clusters = 2880,
ClusterSize = 512,
SystemId = "BeOS ",
VolumeName = "VOLUME LABE",
VolumeSerial = "00000000"
}
};
}
}