Skip to content

Commit

Permalink
Fix travis
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed Jan 8, 2019
1 parent 2b4482f commit 63204cf
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 3 deletions.
Expand Up @@ -39,6 +39,9 @@ The ``render`` argument indicates whether the category should initially be rende
%End

QgsRendererCategory( const QgsRendererCategory &cat );
%Docstring
Copy constructor.
%End

QVariant value() const;
%Docstring
Expand Down
3 changes: 3 additions & 0 deletions src/core/symbology/qgscategorizedsymbolrenderer.h
Expand Up @@ -54,6 +54,9 @@ class CORE_EXPORT QgsRendererCategory
*/
QgsRendererCategory( const QVariant &value, QgsSymbol *symbol SIP_TRANSFER, const QString &label, bool render = true );

/**
* Copy constructor.
*/
QgsRendererCategory( const QgsRendererCategory &cat );
QgsRendererCategory &operator=( QgsRendererCategory cat );

Expand Down
6 changes: 3 additions & 3 deletions tests/src/gui/testqgscategorizedrendererwidget.cpp
Expand Up @@ -248,9 +248,9 @@ void TestQgsCategorizedRendererWidget::model()
QCOMPARE( model->data( model->index( 1, 2 ), Qt::DisplayRole ).toString(), QStringLiteral( "list" ) );
QCOMPARE( model->data( model->index( 2, 2 ), Qt::DisplayRole ).toString(), QStringLiteral( "dd" ) );

QCOMPARE( model->data( model->index( 0, 0 ), Qt::CheckStateRole ).toInt(), Qt::Checked );
QCOMPARE( model->data( model->index( 1, 0 ), Qt::CheckStateRole ).toInt(), Qt::Checked );
QCOMPARE( model->data( model->index( 2, 0 ), Qt::CheckStateRole ).toInt(), Qt::Unchecked );
QCOMPARE( model->data( model->index( 0, 0 ), Qt::CheckStateRole ).toInt(), static_cast< int >( Qt::Checked ) );
QCOMPARE( model->data( model->index( 1, 0 ), Qt::CheckStateRole ).toInt(), static_cast< int >( Qt::Checked ) );
QCOMPARE( model->data( model->index( 2, 0 ), Qt::CheckStateRole ).toInt(), static_cast< int >( Qt::Unchecked ) );
}

QGSTEST_MAIN( TestQgsCategorizedRendererWidget )
Expand Down

0 comments on commit 63204cf

Please sign in to comment.