mpdata/tsrc/unittest_mpcollectiondatamodel/inc/unittest_mpcollectiondatamodel.h
changeset 22 ecf06a08d4d9
child 29 8192e5b5c935
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/mpdata/tsrc/unittest_mpcollectiondatamodel/inc/unittest_mpcollectiondatamodel.h	Mon May 03 12:29:20 2010 +0300
@@ -0,0 +1,92 @@
+/*
+* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
+* All rights reserved.
+* This component and the accompanying materials are made available
+* under the terms of "Eclipse Public License v1.0"
+* which accompanies this distribution, and is available
+* at the URL "http://www.eclipse.org/legal/epl-v10.html".
+*
+* Initial Contributors:
+* Nokia Corporation - initial contribution.
+*
+* Contributors:
+*
+* Description: Unit test for mpcollectiondatamodel
+*
+*/
+
+#ifndef TESTMPCOLLECTIONDATAMODEL_H
+#define TESTMPCOLLECTIONDATAMODEL_H
+
+#include <QtTest/QtTest>
+
+class QTranslator;
+class MpCollectionDataModel;
+class MpMpxCollectionData;
+class TestHelper;
+
+class TestMpCollectionDataModel : public QObject
+{
+    Q_OBJECT
+
+public:
+
+    TestMpCollectionDataModel();
+    virtual ~TestMpCollectionDataModel();
+
+signals:
+
+    void updateAlbumArt( int index );
+    void albumCacheReady();
+
+public slots:
+
+    void initTestCase();
+    void cleanupTestCase();
+    void init();
+    void cleanup();
+
+private slots:
+
+    void testMemberCleanup();
+    void testRefreshModel();
+    void testRefreshModelZeroCount();
+    void testCollectionData();
+    void testDataAllSongs();
+    void testDataAllSongsNoData();
+    void testDataArtists();
+    void testDataArtistsNoData();
+    void testDataArtistAlbums();
+    void testDataArtistAlbumsNoData();
+    void testDataArtistSongs();
+    void testDataArtistSongsNoData();
+    void testDataAlbums();
+    void testDataAlbumsNoData();
+    void testDataAlbumSongs();
+    void testDataAlbumSongsNoData();
+    void testDataPlaylists();
+    void testDataPlaylistsNoData();
+    void testDataPlaylistSongs();
+    void testDataPlaylistSongsNoData();
+    void testDataAnyOtherRole();
+    void testUpdateAlbumArt();
+    void testSupportedDropActions();
+    void testRemoveRows();
+    void testMimeTypes();
+    void testMimeData();
+    void testDropMimeData();
+
+private:
+
+    MpCollectionDataModel   *mTest;
+    TestHelper              *mHelper;
+    MpMpxCollectionData     *mStubData;
+    QTranslator             *mMpTranslator; // Own
+
+};
+
+#endif  // TESTMPCOLLECTIONDATAMODEL_H
+
+
+
+