Exemplo n.º 1
0
        public void ViewAccessibilityEmitTextInsertedEvent()
        {
            tlog.Debug(tag, $"ViewAccessibilityEmitTextInsertedEvent START");

            var testingTarget = new TextLabel()
            {
                Text = "InsertedEvent"
            };

            Assert.IsNotNull(testingTarget, "Can't create success object View");
            Assert.IsInstanceOf <View>(testingTarget, "Should be an instance of View type.");

            try
            {
                testingTarget.EmitTextInsertedEvent(0, 4, "test");
                testingTarget.EmitTextCursorMovedEvent(4);
                testingTarget.EmitTextDeletedEvent(0, 4, "test");
            }
            catch (Exception e)
            {
                tlog.Debug(tag, e.Message.ToString());
                Assert.Fail("Caught Exception : Failed!");
            }

            testingTarget.Dispose();
            tlog.Debug(tag, $"ViewAccessibilityEmitTextInsertedEvent END (OK)");
        }