Пример #1
0
 public ScreenshotTestEngine(IFilePathProvider oldFilePathProvider, IFilePathProvider newFilePathProvider, IScreenshotProvider screenshotProvider, IBitmapComparer bitmapComparer)
 {
     _bitmapComparer      = bitmapComparer;
     _screenshotProvider  = screenshotProvider;
     _newFilePathProvider = newFilePathProvider;
     _oldFilePathProvider = oldFilePathProvider;
 }
Пример #2
0
 internal App(IConsoleLog log, GitRepoProvider git, IScreenshotProvider screenshots, Func <int, IRepeater> repeaterFactory)
 {
     _log             = log;
     _git             = git;
     _repeaterFactory = repeaterFactory;
     _stopwatch       = new Stopwatch();
     _screenshots     = screenshots;
 }
Пример #3
0
    public static void CaptureScreenshot()
    {
        if (instance == null)
        {
#if UNITY_ANDROID
            GameObject temp = new GameObject("AndroidScreenshotProvider");
            temp.AddComponent <AndroidScreenshotProvider>();
            instance = temp.GetComponent <AndroidScreenshotProvider>();
#endif
        }


        if (instance != null)
        {
            instance.CaptureScreenshot();
        }
        else
        {
            Debug.Log("No ScreenshotProvider could be instanced.");
        }
    }
Пример #4
0
 public App(IConsoleLog log, GitRepoProvider git, IScreenshotProvider screenshots)
     : this(log, git, screenshots, intervalSeconds => new Repeater(intervalSeconds))
 {
 }
 public ScreenshotHooks(ScenarioContext scenarioContext, IScreenshotProvider screenshotProvider)
 {
     this.scenarioContext    = scenarioContext;
     this.screenshotProvider = screenshotProvider;
 }
Пример #6
0
 public ScreenshotTestEngine(IFilePathProvider oldFilePathProvider, IFilePathProvider newFilePathProvider,
                             IScreenshotProvider screenshotProvider)
     : this(oldFilePathProvider, newFilePathProvider, screenshotProvider, new BitmapComparer())
 {
 }
Пример #7
0
 public ScreenshotRunner(IScreenshotProvider screenshotProvider, IFilePathProvider filePathProvider)
 {
     _filePathProvider   = filePathProvider;
     _screenshotProvider = screenshotProvider;
 }