Exemplo n.º 1
0
        public void CustomerStatementTest_Execution_Failure_Mock()
        {
            string            wsUrl      = "http://10.0.1.7:8080/mockSI_OS_CustomerStatementBinding_Failure"; // TODO: Initialize to an appropriate value
            CustomerStatement target     = new CustomerStatement(wsUrl);                                      // TODO: Initialize to an appropriate value
            CsParametersDto   parameters = new CsParametersDto()
            {
                IdBusinessEntity = "65603243",
                CDist            = "00",
                IdSOrg           = "7460",
                IdSector         = "03",
                IdDCurr          = "",
                IdFCurr          = ""
            }; // TODO: Initialize to an appropriate value

            var actual   = CustomerStatementTest_LogicExec(wsUrl, "WSPISINCO", "inicio01", parameters);
            var expected = new CsResponseDto()
            {
                Exception = "SHIPTO_NOT_FOUND"
            };

            //Assert.IsTrue(actual.Exception != null);
            Assert.AreEqual(actual.Exception, expected.Exception, "(Actual)" + actual.Exception + "=" + "(Expected)" + expected.Exception);
        }
Exemplo n.º 2
0
        public void CustomerStatementTest_Execution_Regular_Mock()
        {
            string            wsUrl      = "http://10.0.1.7:8088/mockSI_OS_CustomerStatementBinding"; // TODO: Initialize to an appropriate value
            CustomerStatement target     = new CustomerStatement(wsUrl);                              // TODO: Initialize to an appropriate value
            CsParametersDto   parameters = new CsParametersDto()
            {
                IdBusinessEntity = "65603243",
                CDist            = "00",
                IdSOrg           = "7460",
                IdSector         = "03",
                IdDCurr          = "",
                IdFCurr          = ""
            }; // TODO: Initialize to an appropriate value

            var actual   = CustomerStatementTest_LogicExec(wsUrl, "WSPISINCO", "inicio01", parameters);
            var expected = new CsResponseDto()
            {
                NBusinessEntity     = "MESA DE YEGUAS V 70",
                IdBlqBusinessEntity = "00",
                NBlqBusinessEntity  = "Not blocked customer",
                IdCliente           = "0050301790",
                NCliente            = "JOSOA SAS",
                IdBlqCliente        = "00",
                NBlqCliente         = "Not blocked customer",
                IdCpObra            = "ZCOC",
                NCpObra             = "(AR) Payable immediately Due net",
                CartT     = "0.0000",
                SldAf     = "1502051.0000-",
                CartN     = "1502051.0000-",
                LimCr     = "0.0000",
                FConvCurr = "42.00",
                VComp     = "0.0000",
                Exception = null
            };

            Assert.IsTrue(expected.NBusinessEntity == actual.NBusinessEntity, "(Expected)" + expected.NBusinessEntity + "=" + "(Actual)" + actual.NBusinessEntity);
        }