Make Mr. Travis happy

This commit is contained in:
Matthias Kuhn 2017-09-28 11:50:30 +02:00
parent 3562af4db7
commit e025011799
No known key found for this signature in database
GPG Key ID: A0E766808764D73F
4 changed files with 6 additions and 4 deletions

View File

@ -44,6 +44,7 @@ def _geometryNonZero(self):
def _isValid(self):
return self.isValid()
QgsGeometry.__nonzero__ = _geometryNonZero
QgsGeometry.__bool__ = _geometryNonZero

View File

@ -191,8 +191,8 @@ Gets variant type of the field as it will be retrieved from data source
void setDefaultValueDefinition( const QgsDefaultValue &defaultValueDefinition );
%Docstring
Sets an expression to use when calculating the default value for the field.
\param expression expression to evaluate when calculating default values for field. Pass
an empty expression to clear the default.
\param defaultValueDefinition expression to evaluate when calculating default values for field. Pass
a default constructed QgsDefaultValue() to reset.
.. versionadded:: 3.0
.. seealso:: defaultValueDefinition()
%End

View File

@ -203,8 +203,8 @@ class CORE_EXPORT QgsField
QgsDefaultValue defaultValueDefinition() const;
/** Sets an expression to use when calculating the default value for the field.
* \param expression expression to evaluate when calculating default values for field. Pass
* an empty expression to clear the default.
* \param defaultValueDefinition expression to evaluate when calculating default values for field. Pass
* a default constructed QgsDefaultValue() to reset.
* \since QGIS 3.0
* \see defaultValueDefinition()
*/

View File

@ -40,5 +40,6 @@ class TestQgsRasterColorRampShader(unittest.TestCase):
value.setApplyOnUpdate(True)
self.assertEqual(value.applyOnUpdate(), True)
if __name__ == '__main__':
unittest.main()