Nut/test/basic/maintest.h

38 lines
678 B
C
Raw Normal View History

2016-05-12 14:08:58 +08:00
#ifndef MAINTEST_H
#define MAINTEST_H
#include <QtCore/QObject>
#include <QtCore/qglobal.h>
#include "weblogdatabase.h"
2016-05-21 16:09:03 +08:00
class Post;
2016-05-12 14:08:58 +08:00
class MainTest : public QObject
{
Q_OBJECT
WeblogDatabase db;
int postId;
2016-05-21 16:09:03 +08:00
Post *post;
2016-05-12 14:08:58 +08:00
public:
explicit MainTest(QObject *parent = 0);
signals:
private slots:
void initTestCase();
void dataScheema();
void createPost();
2016-06-05 20:22:26 +08:00
void createPost2();
2016-05-12 14:08:58 +08:00
void selectPosts();
2016-06-05 20:22:26 +08:00
void selectPostsWithoutTitle();
2017-09-10 22:18:20 +08:00
void selectPostIds();
2016-05-21 16:09:03 +08:00
void testDate();
2018-01-09 00:59:16 +08:00
void join();
2016-05-12 14:08:58 +08:00
void selectWithInvalidRelation();
2016-06-05 20:22:26 +08:00
void select10NewstPosts();
2016-05-12 14:08:58 +08:00
void modifyPost();
2017-08-09 21:19:35 +08:00
void emptyDatabase();
2016-05-12 14:08:58 +08:00
};
#endif // MAINTEST_H