Esempio n. 1
0
        public void DefaultRulerConstructor()
        {
            tlog.Debug(tag, $"DefaultRulerConstructor START");

            var testingTarget = new DefaultRuler();

            Assert.IsNotNull(testingTarget, "Can't create success object DefaultRuler.");
            Assert.IsInstanceOf <DefaultRuler>(testingTarget, "Should return DefaultRuler instance.");

            testingTarget.Dispose();
            tlog.Debug(tag, $"DefaultRulerConstructor END (OK)");
        }
Esempio n. 2
0
        public void DefaultRulerGetPositionFromPage()
        {
            tlog.Debug(tag, $"DefaultRulerGetPositionFromPage START");

            var testingTarget = new DefaultRuler();

            Assert.IsNotNull(testingTarget, "Can't create success object DefaultRuler.");
            Assert.IsInstanceOf <DefaultRuler>(testingTarget, "Should return DefaultRuler instance.");

            try
            {
                var result = testingTarget.GetPositionFromPage(1, out uint vloume, true);
                tlog.Debug(tag, "GetPositionFromPage :" + result);
            }
            catch (Exception e)
            {
                tlog.Debug(tag, e.Message.ToString());
                Assert.Fail("Caught Exception : Failed!");
            }

            testingTarget.Dispose();
            tlog.Debug(tag, $"DefaultRulerGetPositionFromPage END (OK)");
        }
Esempio n. 3
0
        public void DefaultRulerSnap()
        {
            tlog.Debug(tag, $"DefaultRulerSnap START");

            var testingTarget = new DefaultRuler();

            Assert.IsNotNull(testingTarget, "Can't create success object DefaultRuler.");
            Assert.IsInstanceOf <DefaultRuler>(testingTarget, "Should return DefaultRuler instance.");

            try
            {
                var result = testingTarget.Snap(0.3f, 0.1f);
                tlog.Debug(tag, "Snap :" + result);
            }
            catch (Exception e)
            {
                tlog.Debug(tag, e.Message.ToString());
                Assert.Fail("Caught Exception : Failed!");
            }

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