コード例 #1
0
        internal VisualGridEyes(ISeleniumConfigurationProvider configurationProvider, VisualGridRunner visualGridRunner)
        {
            ArgumentGuard.NotNull(visualGridRunner, nameof(visualGridRunner));
            if (visualGridRunner.GetAllTestResultsAlreadyCalled)
            {
                throw new InvalidOperationException("Runner already returned its results");
            }
            configProvider_ = configurationProvider;
            Logger          = visualGridRunner.Logger;
            runner_         = visualGridRunner;

            IDebugResourceWriter drw = runner_.DebugResourceWriter;

            Ufg.IDebugResourceWriter ufgDrw = EyesSeleniumUtils.ConvertDebugResourceWriter(drw);
            debugResourceWriter_ = ufgDrw;
        }
コード例 #2
0
        internal VisualGridEyes(ISeleniumConfigurationProvider configurationProvider, VisualGridRunner visualGridRunner)
        {
            ArgumentGuard.NotNull(visualGridRunner, nameof(visualGridRunner));
            configProvider_      = configurationProvider;
            Logger               = visualGridRunner.Logger;
            visualGridRunner_    = visualGridRunner;
            debugResourceWriter_ = visualGridRunner_.DebugResourceWriter ?? NullDebugResourceWriter.Instance;
            testListener_        = new RunningTest.RunningTestListener(
                (task, test) =>
            {
                if (task.TaskType == TaskType.Close || task.TaskType == TaskType.Abort)
                {
                    hasEyesIssuedOpenTasks_ = false;
                }
                listener_?.OnTaskComplete(task, this);
            },

                () => listener_?.OnRenderComplete());
        }