public void WithDifferringPeriodAreNotEqual(ProviderAdjustment earning1,
                                                    ProviderAdjustment earning2)
        {
            earning2.PaymentType = earning1.PaymentType;
            earning2.Ukprn       = earning1.Ukprn;

            var sut  = new ProviderAdjustmentPaymentGrouping(earning1);
            var test = new ProviderAdjustmentPaymentGrouping(earning2);

            var actual = sut.GetHashCode() == test.GetHashCode();

            actual.Should().BeFalse();
        }
        public void WithSameUkprnPaymentTypeAndPeriodAreSame(ProviderAdjustment earning1,
                                                             ProviderAdjustment earning2)
        {
            earning2.PaymentType = earning1.PaymentType;
            earning2.SubmissionCollectionPeriod = earning1.SubmissionCollectionPeriod;
            earning2.Ukprn = earning1.Ukprn;

            var sut  = new ProviderAdjustmentPaymentGrouping(earning1);
            var test = new ProviderAdjustmentPaymentGrouping(earning2);

            var actual = sut.GetHashCode() == test.GetHashCode();

            actual.Should().BeTrue();
        }
        public void WithDifferringPeriodAreNotEqual(
            ProviderAdjustment earning1,
            ProviderAdjustment earning2)
        {
            earning2.PaymentType = earning1.PaymentType;
            earning2.Ukprn       = earning1.Ukprn;

            var sut  = new ProviderAdjustmentPaymentGrouping(earning1);
            var test = new ProviderAdjustmentPaymentGrouping(earning2);

            var actual = sut == test;

            actual.Should().BeFalse();
            earning1.SubmissionCollectionPeriod.Should().NotBe(earning2.SubmissionCollectionPeriod);
        }
        public void WithDifferninSubmissionIdSame(
            ProviderAdjustment earning1,
            ProviderAdjustment earning2)
        {
            earning2.PaymentType = earning1.PaymentType;
            earning2.SubmissionCollectionPeriod = earning1.SubmissionCollectionPeriod;
            earning2.Ukprn = earning1.Ukprn;

            var sut  = new ProviderAdjustmentPaymentGrouping(earning1);
            var test = new ProviderAdjustmentPaymentGrouping(earning2);

            var actual = sut == test;

            actual.Should().BeTrue();
            earning1.SubmissionId.Should().NotBe(earning2.SubmissionId);
        }