~ubuntu-branches/ubuntu/oneiric/pyside/oneiric

« back to all changes in this revision

Viewing changes to tests/QtGui/qmenuadd_test.py

  • Committer: Bazaar Package Importer
  • Author(s): Didier Raboud
  • Date: 2010-09-27 21:01:06 UTC
  • mfrom: (1.2.1 upstream) (6.1.3 experimental)
  • Revision ID: james.westby@ubuntu.com-20100927210106-m1nrq8vmd3exqb9o
Tags: 0.4.1-0ubuntu1
* New 0.4.1 upstream release. (LP: #648612)
  - Add some 0.4.1 symbols.

* Patches:
  - u_c130273_fix_py25_QtScript_property.patch
    Remove, was from upstream.
  - u_20e226b_fix_missing_qcoreapplication_arguments_method.patch
    Remove, was from upstream.
  - u_268bf77_fixed_signal_signature_parser.patch
    Remove, was from upstream.
  + libPythonVersionPostfix.patch: Refresh
  + usePySpecificShiboken.patch: Refresh
  + lessBuildVerbosity.patch: Refresh

* Bump the B-D chain versions.
* Make sure the private.py is installed in QtCore module.
* Build against Qt 4.7.
  - Add libqtwebkit-dev
  - Drop QtMultimedia module.
  - Add the QtDeclarative package.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# -*- coding: utf-8 -*-
 
2
 
 
3
''' Test the QMenu.addAction() method'''
 
4
 
 
5
import unittest
 
6
import sys
 
7
 
 
8
from PySide import QtGui
 
9
 
 
10
from helper import UsesQApplication
 
11
 
 
12
class QMenuAddAction(UsesQApplication):
 
13
 
 
14
    def openFile(self, *args):
 
15
        self.arg = args
 
16
 
 
17
    def testQMenuAddAction(self):
 
18
        fileMenu = QtGui.QMenu("&File")
 
19
 
 
20
        addNewAction = fileMenu.addAction("&Open...", self.openFile)
 
21
        addNewAction.trigger()
 
22
        self.assertEquals(self.arg, ())
 
23
 
 
24
if __name__ == '__main__':
 
25
    unittest.main()