aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorRenato Filho <renato.filho@openbossa.org>2010-05-20 10:57:14 -0300
committerRenato Filho <renato.filho@openbossa.org>2010-05-20 12:16:54 -0300
commit361ac438c2b9e3c6c10c9ab2207a6464557b8a85 (patch)
tree295aa33dd306831480278d78f2114dc8d41dc6b2 /tests
parent3d205e83191fa778d9e17e318cff28829abfa62d (diff)
Fixed signal/slot class name based on PSEP 100.
Reviewer: Hugo Parente Lima <hugo.lima@openbossa.org>, Luciano Wolf <luciano.wolf@openbossa.org>
Diffstat (limited to 'tests')
-rw-r--r--tests/signals/decorators_test.py12
-rwxr-xr-xtests/signals/ref01_test.py6
-rwxr-xr-xtests/signals/ref04_test.py4
-rwxr-xr-xtests/signals/ref05_test.py4
-rwxr-xr-xtests/signals/ref06_test.py6
-rw-r--r--tests/signals/signal_autoconnect_test.py2
-rw-r--r--tests/signals/signal_object_test.py12
7 files changed, 23 insertions, 23 deletions
diff --git a/tests/signals/decorators_test.py b/tests/signals/decorators_test.py
index db068d00..a6a8572b 100644
--- a/tests/signals/decorators_test.py
+++ b/tests/signals/decorators_test.py
@@ -11,24 +11,24 @@ class MyObject(QObject):
QObject.__init__(self, parent)
self._slotCalledCount = 0
- @Slot()
+ @slot()
def mySlot(self):
self._slotCalledCount = self._slotCalledCount + 1
- @Slot(int)
- @Slot('QString')
+ @slot(int)
+ @slot('QString')
def mySlot2(self, arg0):
self._slotCalledCount = self._slotCalledCount + 1
- @Slot(name='mySlot3')
+ @slot(name='mySlot3')
def foo(self):
self._slotCalledCount = self._slotCalledCount + 1
- @Slot(QString, int)
+ @slot(QString, int)
def mySlot4(self, a, b):
self._slotCalledCount = self._slotCalledCount + 1
- @Slot(result=int)
+ @slot(result=int)
def mySlot5(self):
self._slotCalledCount = self._slotCalledCount + 1
diff --git a/tests/signals/ref01_test.py b/tests/signals/ref01_test.py
index ba6839ec..6f30bf50 100755
--- a/tests/signals/ref01_test.py
+++ b/tests/signals/ref01_test.py
@@ -2,7 +2,7 @@
# -*- coding: utf-8 -*-
import unittest
-from PySide.QtCore import QObject, Signal
+from PySide.QtCore import QObject, signal
class BoundAndUnboundSignalsTest(unittest.TestCase):
@@ -13,12 +13,12 @@ class BoundAndUnboundSignalsTest(unittest.TestCase):
del self.methods
def testUnboundSignal(self):
- self.assertEqual(type(QObject.destroyed), Signal)
+ self.assertEqual(type(QObject.destroyed), signal)
self.assertFalse(self.methods.issubset(dir(QObject.destroyed)))
def testBoundSignal(self):
obj = QObject()
- self.assertNotEqual(type(obj.destroyed), Signal)
+ self.assertNotEqual(type(obj.destroyed), signal)
self.assert_(self.methods.issubset(dir(obj.destroyed)))
if __name__ == '__main__':
diff --git a/tests/signals/ref04_test.py b/tests/signals/ref04_test.py
index 88a59f68..4ca22398 100755
--- a/tests/signals/ref04_test.py
+++ b/tests/signals/ref04_test.py
@@ -2,11 +2,11 @@
# -*- coding: utf-8 -*-
import unittest
-from PySide.QtCore import QObject, Signal
+from PySide.QtCore import QObject, signal
class ExtQObject(QObject):
- mySignal = Signal()
+ mySignal = signal()
def __init__(self):
QObject.__init__(self)
diff --git a/tests/signals/ref05_test.py b/tests/signals/ref05_test.py
index 7c53300a..e4124814 100755
--- a/tests/signals/ref05_test.py
+++ b/tests/signals/ref05_test.py
@@ -2,7 +2,7 @@
# -*- coding: utf-8 -*-
import unittest
-from PySide.QtCore import QObject, QCoreApplication, QTimeLine, Slot
+from PySide.QtCore import QObject, QCoreApplication, QTimeLine, slot
from helper import UsesQCoreApplication
class ExtQObject(QObject):
@@ -11,7 +11,7 @@ class ExtQObject(QObject):
QObject.__init__(self)
self.counter = 0
- @Slot('qreal')
+ @slot('qreal')
def foo(self, value):
self.counter += 1
diff --git a/tests/signals/ref06_test.py b/tests/signals/ref06_test.py
index 05712b3b..cefa1f2c 100755
--- a/tests/signals/ref06_test.py
+++ b/tests/signals/ref06_test.py
@@ -2,17 +2,17 @@
# -*- coding: utf-8 -*-
import unittest
-from PySide.QtCore import QObject, QCoreApplication, QTimeLine, Signal, Slot
+from PySide.QtCore import QObject, QCoreApplication, QTimeLine, signal, slot
from helper import UsesQCoreApplication
class ExtQObject(QObject):
- signalbetween = Signal('qreal')
+ signalbetween = signal('qreal')
def __init__(self):
QObject.__init__(self)
self.counter = 0
- @Slot('qreal')
+ @slot('qreal')
def foo(self, value):
self.counter += 1
diff --git a/tests/signals/signal_autoconnect_test.py b/tests/signals/signal_autoconnect_test.py
index d3e74910..d1727334 100644
--- a/tests/signals/signal_autoconnect_test.py
+++ b/tests/signals/signal_autoconnect_test.py
@@ -10,7 +10,7 @@ class MyObject(QWidget):
QWidget.__init__(self, parent)
self._method_called = False
- @Slot()
+ @slot()
def on_button_clicked(self):
self._method_called = True
diff --git a/tests/signals/signal_object_test.py b/tests/signals/signal_object_test.py
index 614c0e60..53bd4eed 100644
--- a/tests/signals/signal_object_test.py
+++ b/tests/signals/signal_object_test.py
@@ -8,14 +8,14 @@ from PySide.QtCore import *
from helper import UsesQCoreApplication
class MyObject(QTimer):
- sig1 = Signal()
- sig2 = Signal(int, name='rangeChanged')
- sig3 = Signal(int)
- sig4 = Signal((int,), (QString,))
- sig5 = Signal((QString,), (int,))
+ sig1 = signal()
+ sig2 = signal(int, name='rangeChanged')
+ sig3 = signal(int)
+ sig4 = signal((int,), (QString,))
+ sig5 = signal((QString,), (int,))
- @Slot(int)
+ @slot(int)
def myRange(self, r):
self._range = r