示例#1
0
        public void InternalBuildStep_GetHashCode_NullProject()
        {
            IProject          project    = null;
            int               number     = 0;
            StepType          type       = StepType.All;
            string            inputFile  = @"C:\Users\Test\Project\input.asm";
            string            outputFile = @"C:\Users\Test\Project\output.bin";
            InternalBuildStep target     = new InternalBuildStep(project, number, type, inputFile, outputFile);
            InternalBuildStep target2    = new InternalBuildStep(project, number, type, inputFile, outputFile);

            bool expected = true;
            bool actual   = target.GetHashCode() == target2.GetHashCode();

            Assert.AreEqual(expected, actual);
        }
示例#2
0
        public void InternalBuildStep_GetHashCode()
        {
            Mock <IProject> mockProject = new Mock <IProject>(MockBehavior.Strict);

            IProject          project    = mockProject.Object;
            int               number     = 0;
            StepType          type       = StepType.All;
            string            inputFile  = @"C:\Users\Test\Project\input.asm";
            string            outputFile = @"C:\Users\Test\Project\output.bin";
            InternalBuildStep target     = new InternalBuildStep(project, number, type, inputFile, outputFile);
            InternalBuildStep target2    = new InternalBuildStep(project, number, type, inputFile, outputFile);

            bool expected = true;
            bool actual   = target.GetHashCode() == target2.GetHashCode();

            Assert.AreEqual(expected, actual);

            mockProject.Verify();
        }