Changeset 964


Ignore:
Timestamp:
Dec 7, 2009, 10:37:37 PM (12 years ago)
Author:
pretzsch
Message:

+ Rewrote and added MD5 tests to DevTestMethods project

  • Removed MD5Test project
Location:
trunk
Files:
4 added
1 deleted
1 edited
2 copied

Legend:

Unmodified
Added
Removed
  • trunk/DevTestMethods/DevTestMethods.csproj

    r419 r964  
    4141  </ItemGroup>
    4242  <ItemGroup>
     43    <Compile Include="MD5\Algorithm\PresentableMD5Test.cs" />
     44    <Compile Include="MD5\Presentation\Helpers\PresentationControlFactoryTest.cs" />
    4345    <Compile Include="Properties\AssemblyInfo.cs" />
    4446    <Compile Include="pkcsTest.cs" />
     
    5153      <Project>{25DB2B47-A457-4EC2-960B-395CE07AE093}</Project>
    5254      <Name>CrypPluginBase</Name>
     55    </ProjectReference>
     56    <ProjectReference Include="..\CrypPlugins\MD5\MD5.csproj">
     57      <Project>{1137719A-7468-4DEF-84B1-77AB82049656}</Project>
     58      <Name>MD5</Name>
    5359    </ProjectReference>
    5460    <ProjectReference Include="..\CrypPlugins\PKCS5\PKCS5.csproj">
  • trunk/DevTestMethods/MD5/Algorithm/PresentableMD5Test.cs

    r963 r964  
    33using System.Linq;
    44using System.Text;
    5 using NUnit.Framework;
    65using System.IO;
    76using Cryptool.MD5.Algorithm;
     7using Microsoft.VisualStudio.TestTools.UnitTesting;
    88
    99namespace Test.Cryptool.MD5.Algorithm
    1010{
    11     [TestFixture]
    12     class PresentableMD5Test
     11    [TestClass]
     12    public class PresentableMD5Test
    1313    {
    1414        Random RNG;
    1515
    16         [SetUp]
    17         public void SetUp()
     16        [TestInitialize]
     17        public void Initialize()
    1818        {
    1919            RNG = new Random();
    2020        }
    2121
    22         [Test]
     22        [TestMethod]
    2323        public void Construction()
    2424        {
     
    2626        }
    2727
    28         [Test]
     28        [TestMethod]
    2929        public void UninitializedStateAfterConstruction()
    3030        {
     
    3434        }
    3535
    36         [Test]
     36        [TestMethod]
    3737        public void InitializedStateAfterInitialization()
    3838        {
     
    4444        }
    4545
    46         [Test]
     46        [TestMethod]
    4747        public void VerifyResultsForRandomData()
    4848        {
    49             const int TEST_RUNS = 20;
     49            const int TEST_RUNS = 10;
    5050            const int MIN_TEST_DATA_LENGTH = 1;
    5151            const int MAX_TEST_DATA_LENGTH = 1000;
     
    5858        }
    5959
    60         [Test]
     60        [TestMethod]
    6161        public void VerifyResultForEmptyData()
    6262        {
     
    6464        }
    6565
    66         [Test]
     66        [TestMethod]
    6767        public void VerifyResultsForRandomDataWithInterestingLength()
    6868        {
     
    8282            byte[] presentableMD5Result = presentableMD5.HashValueBytes;
    8383
    84             Assert.AreEqual(builtinResult, presentableMD5Result);
     84            CollectionAssert.AreEqual(builtinResult, presentableMD5Result);
    8585        }
    8686
  • trunk/DevTestMethods/MD5/Presentation/Helpers/PresentationControlFactoryTest.cs

    r963 r964  
    33using System.Linq;
    44using System.Text;
    5 using NUnit.Framework;
    65using Cryptool.MD5.Presentation.Helpers;
     6using Microsoft.VisualStudio.TestTools.UnitTesting;
    77
    88namespace Test.Cryptool.MD5.Presentation.Helpers
    99{
    10     [TestFixture]
    11     class PresentationControlFactoryTest
     10    [TestClass]
     11    public class PresentationControlFactoryTest
    1212    {
    13         [Test]
    14         void Construction()
     13        [TestMethod]
     14        public void Construction()
    1515        {
    1616            new PresentationControlFactory();
Note: See TracChangeset for help on using the changeset viewer.