[gnome-settings-daemon/gnome-3-30] tests: Fix deprecation warning



commit 889f51a51513e4dfea979b320d8a2a77cdaa77fb
Author: Carlos Garnacho <carlosg gnome org>
Date:   Wed Nov 14 21:51:04 2018 +0100

    tests: Fix deprecation warning
    
    The xsettings test is failing with:
    
    /home/carlos/Source/gnome/gnome-settings-daemon/plugins/xsettings/test.py:84: PyGIDeprecationWarning: 
Using positional arguments with the GObject constructor has been deprecated. Please specify keyword(s) for 
"schema" or use a class specific constructor. See: https://wiki.gnome.org/PyGObject/InitializerDeprecations
      self.settings_sound = Gio.Settings('org.gnome.desktop.sound')
    
    (cherry picked from commit 63e325a44e89996f026f258521dc57f016f163d7)

 plugins/xsettings/test.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/plugins/xsettings/test.py b/plugins/xsettings/test.py
index e1bd9407..2f203793 100755
--- a/plugins/xsettings/test.py
+++ b/plugins/xsettings/test.py
@@ -81,7 +81,7 @@ class XsettingsPluginTest(gsdtestcase.GSDTestCase):
         shutil.copy(os.path.join(os.path.dirname(__file__), 'gtk-modules-test/pk-gtk-module.desktop'),
                 os.path.join(modules_dir, 'pk-gtk-module.desktop'))
 
-        self.settings_sound = Gio.Settings('org.gnome.desktop.sound')
+        self.settings_sound = Gio.Settings.new('org.gnome.desktop.sound')
 
         env = os.environ.copy()
         self.daemon = subprocess.Popen(


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