[gnome-continuous] testbase: use save if its available and fallback to savev if not



commit 582e0aedd909cc59ae66474ae11077455bb41cbe
Author: Vadim Rutkovsky <vrutkovs redhat com>
Date:   Mon Jan 26 16:13:38 2015 +0100

    testbase: use save if its available and fallback to savev if not
    
    See https://bugzilla.gnome.org/show_bug.cgi?id=670372

 src/js/tasks/testbase.js |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)
---
diff --git a/src/js/tasks/testbase.js b/src/js/tasks/testbase.js
index 4013735..af5be1e 100644
--- a/src/js/tasks/testbase.js
+++ b/src/js/tasks/testbase.js
@@ -283,7 +283,12 @@ const TestOneDisk = new Lang.Class({
             if (pixbuf != null) {
                 let outFilename = this._subworkdir.get_child(filename.replace(/ppm$/, 'png'));
                 screenshotPath = outFilename;
-                pixbuf.savev(outFilename.get_path(), "png", [], []);
+                if (pixbuf.save) {
+                    pixbuf.save(outFilename.get_path(), "png", [], []);
+                } else {
+                    pixbuf.savev(outFilename.get_path(), "png", [], []);
+                }
+
             }
             GSystem.file_unlink(filePath, this._cancellable);
         }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]