Skip to content
Permalink
Browse files

Fix failing tests

  • Loading branch information
nyalldawson committed Jul 24, 2017
1 parent 78b05c1 commit 7e749a5afb6eadafb4cc85ecbba6c17f795701c2
0 src/core/qgsunittypes.cpp 100755 → 100644
No changes.
@@ -69,6 +69,9 @@ void QgsSymbolButton::setSymbolType( QgsSymbol::SymbolType type )
case QgsSymbol::Fill:
mSymbol.reset( QgsFillSymbol::createSimple( QgsStringMap() ) );
break;

case QgsSymbol::Hybrid:
break;
}
}
updatePreview();
No changes.
@@ -39,7 +39,7 @@ def testGettersSetters(self):
button.setSymbolType(QgsSymbol.Line)
self.assertEqual(button.symbolType(), QgsSymbol.Line)

def testSettingSymbolType(self)
def testSettingSymbolType(self):
button = QgsSymbolButton()
button.setSymbolType(QgsSymbol.Marker)
symbol = QgsMarkerSymbol.createSimple({})
@@ -74,7 +74,7 @@ def testPasteSymbol(self):
# try pasting incompatible symbol
button2.setSymbolType(QgsSymbol.Fill)
fill_symbol = QgsFillSymbol.createSimple({})
fill_symbol.setColor(QColor(0,0,255))
fill_symbol.setColor(QColor(0, 0, 255))
button2.setSymbol(fill_symbol)
button.copySymbol() # copied a marker symbol
button2.pasteSymbol() # should have no effect
@@ -15,6 +15,7 @@
import qgis # NOQA

from qgis.core import QgsSymbolLayerUtils, QgsMarkerSymbol
from qgis.PyQt.QtGui import QColor
from qgis.PyQt.QtCore import QSizeF, QPointF
from qgis.testing import unittest

0 comments on commit 7e749a5

Please sign in to comment.
You can’t perform that action at this time.