예제 #1
0
        public void VerifyResult()
        {
            SignatureStylesExample example = new SignatureStylesExample();

            example.Run();

            DocumentPackage documentPackage = example.RetrievedPackage;

            foreach (Signature signature in documentPackage.GetDocument(example.DOCUMENT_NAME).Signatures)
            {
                if ((int)(signature.X + 0.1) == example.FULL_NAME_SIGNATURE_POSITION_X && (int)(signature.Y + 0.1) == example.FULL_NAME_SIGNATURE_POSITION_Y)
                {
                    Assert.AreEqual(signature.Style, SignatureStyle.FULL_NAME);
                    Assert.AreEqual(signature.Page, example.FULL_NAME_SIGNATURE_PAGE);
                }
                if ((int)(signature.X + 0.1) == example.INITIAL_SIGNATURE_POSITION_X && (int)(signature.Y + 0.1) == example.INITIAL_SIGNATURE_POSITION_Y)
                {
                    Assert.AreEqual(signature.Style, SignatureStyle.INITIALS);
                    Assert.AreEqual(signature.Page, example.INITIAL_SIGNATURE_PAGE);
                }
                if ((int)(signature.X + 0.1) == example.HAND_DRAWN_SIGNATURE_POSITION_X && (int)(signature.Y + 0.1) == example.HAND_DRAWN_SIGNATURE_POSITION_Y)
                {
                    Assert.AreEqual(signature.Style, SignatureStyle.HAND_DRAWN);
                    Assert.AreEqual(signature.Page, example.HAND_DRAWN_SIGNATURE_PAGE);
                }
            }
        }
        public void VerifyResult()
        {
            SignatureStylesExample example = new SignatureStylesExample(Props.GetInstance());
            example.Run();

            DocumentPackage documentPackage = example.EslClient.GetPackage(example.PackageId);

            foreach (Signature signature in documentPackage.Documents[example.DOCUMENT_NAME].Signatures)
            {
                if ((int)(signature.X + 0.1) == example.FULL_NAME_SIGNATURE_POSITION_X && (int)(signature.Y + 0.1) == example.FULL_NAME_SIGNATURE_POSITION_Y)
                {
                    Assert.AreEqual(signature.Style, SignatureStyle.FULL_NAME);
                    Assert.AreEqual(signature.Page, example.FULL_NAME_SIGNATURE_PAGE);
                }
                if ((int)(signature.X + 0.1) == example.INITIAL_SIGNATURE_POSITION_X && (int)(signature.Y + 0.1) == example.INITIAL_SIGNATURE_POSITION_Y)
                {
                    Assert.AreEqual(signature.Style, SignatureStyle.INITIALS);
                    Assert.AreEqual(signature.Page, example.INITIAL_SIGNATURE_PAGE);
                }
                if ((int)(signature.X + 0.1) == example.HAND_DRAWN_SIGNATURE_POSITION_X && (int)(signature.Y + 0.1) == example.HAND_DRAWN_SIGNATURE_POSITION_Y)
                {
                    Assert.AreEqual(signature.Style, SignatureStyle.HAND_DRAWN);
                    Assert.AreEqual(signature.Page, example.HAND_DRAWN_SIGNATURE_PAGE);
                }
            }
        }
예제 #3
0
        public void VerifyResult()
        {
            SignatureStylesExample example = new SignatureStylesExample(Props.GetInstance());

            example.Run();

            DocumentPackage documentPackage = example.EslClient.GetPackage(example.PackageId);

            foreach (Signature signature in documentPackage.Documents[example.DOCUMENT_NAME].Signatures)
            {
                if ((int)(signature.X + 0.1) == example.FULL_NAME_SIGNATURE_POSITION_X && (int)(signature.Y + 0.1) == example.FULL_NAME_SIGNATURE_POSITION_Y)
                {
                    Assert.AreEqual(signature.Style, SignatureStyle.FULL_NAME);
                    Assert.AreEqual(signature.Page, example.FULL_NAME_SIGNATURE_PAGE);
                }
                if ((int)(signature.X + 0.1) == example.INITIAL_SIGNATURE_POSITION_X && (int)(signature.Y + 0.1) == example.INITIAL_SIGNATURE_POSITION_Y)
                {
                    Assert.AreEqual(signature.Style, SignatureStyle.INITIALS);
                    Assert.AreEqual(signature.Page, example.INITIAL_SIGNATURE_PAGE);
                }
                if ((int)(signature.X + 0.1) == example.HAND_DRAWN_SIGNATURE_POSITION_X && (int)(signature.Y + 0.1) == example.HAND_DRAWN_SIGNATURE_POSITION_Y)
                {
                    Assert.AreEqual(signature.Style, SignatureStyle.HAND_DRAWN);
                    Assert.AreEqual(signature.Page, example.HAND_DRAWN_SIGNATURE_PAGE);
                }
            }
        }