Skip to content

Commit d375c5b

Browse files
author
timlinux
committed
Make the unit test more explicitly test result size and use a proper attribute list
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@14400 c8812cc2-4d05-0410-92ff-de0c093fc19c
1 parent c179366 commit d375c5b

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

tests/src/core/testqgsvectorlayer.cpp

+5-2
Original file line numberDiff line numberDiff line change
@@ -146,15 +146,18 @@ class TestQgsVectorLayer: public QObject
146146
{
147147
QgsVectorDataProvider * myProvider = mpNonSpatialLayer->dataProvider();
148148
QgsFeature f;
149+
QgsAttributeList myList;
150+
myList << 0 << 1 << 2 << 3;
149151
int myCount = 0;
150-
myProvider->select();
152+
myProvider->select( myList );
151153
while ( myProvider->nextFeature( f ) )
152154
{
153155
qDebug("Getting feature from provider");
154156
myCount++;
155157
}
156-
QVERIFY( myCount > 10);
158+
QVERIFY( myCount == 3 );
157159
};
160+
158161
void QgsVectorLayerstorageType()
159162
{
160163

0 commit comments

Comments
 (0)