public void Should_Success_Validate_Null_Invoice_Data()
        {
            GarmentFinanceMemorialDetailViewModel vm = new GarmentFinanceMemorialDetailViewModel();

            vm.TotalAmount = 100;
            vm.Items       = new List <GarmentFinanceMemorialDetailItemViewModel>
            {
                new GarmentFinanceMemorialDetailItemViewModel()
                {
                    InvoiceId = 0
                }
            };
            vm.OtherItems = new List <GarmentFinanceMemorialDetailOtherItemViewModel>
            {
                new GarmentFinanceMemorialDetailOtherItemViewModel()
                {
                    Account = null,
                    Amount  = 0,
                }
            };
            vm.RupiahItems = new List <GarmentFinanceMemorialDetailRupiahItemViewModel>
            {
                new GarmentFinanceMemorialDetailRupiahItemViewModel()
                {
                    Account = null,
                    Credit  = 0,
                    Debit   = 0,
                }
            };

            Assert.True(vm.Validate(null).Count() > 0);
        }
        public void Should_Success_Validate_Amount_Different()
        {
            GarmentFinanceMemorialDetailViewModel vm = new GarmentFinanceMemorialDetailViewModel();

            vm.Amount = 3;
            vm.Items  = new List <GarmentFinanceMemorialDetailItemViewModel>
            {
                new GarmentFinanceMemorialDetailItemViewModel()
                {
                    Amount = 1,
                }
            };
            vm.OtherItems = new List <GarmentFinanceMemorialDetailOtherItemViewModel>
            {
                new GarmentFinanceMemorialDetailOtherItemViewModel()
                {
                    TypeAmount = "KREDIT",
                    Amount     = 1,
                },
            };

            Assert.True(vm.Validate(null).Count() > 0);
        }
        public void Should_Success_Validate_All_Null_Data()
        {
            GarmentFinanceMemorialDetailViewModel vm = new GarmentFinanceMemorialDetailViewModel();

            Assert.True(vm.Validate(null).Count() > 0);
        }