Skip to content
Snippets Groups Projects
Commit c4adee4f authored by Armin Felder's avatar Armin Felder
Browse files

added mongodump

parent efe729fc
No related branches found
No related tags found
1 merge request!42Citests
Pipeline #
Showing
with 17 additions and 8 deletions
......@@ -120,7 +120,7 @@ void ApiCompatTests::testDDPSubscriptions()
QSharedPointer<RocketChatNotifyNoticesRequest> notifyNoticeSubSubscription( new RocketChatNotifyNoticesRequest( this->mUserId ) );
QSharedPointer<RocketChatSubScriptionChangedRequest> noitfySubscriptionsSubscription( new RocketChatSubScriptionChangedRequest( this->mUserId ) );
QSharedPointer<RocketChatSubscribeActiveUsers> activeUsersSubscription( new RocketChatSubscribeActiveUsers() );
QSharedPointer<RocketChatSubscribeChannelRequest> testUser1ChannelSub( new RocketChatSubscribeChannelRequest( "azGA4Zy5ACRoBkn6KkX7dHQgXjJcwqaLSm" ) );
QSharedPointer<RocketChatSubscribeChannelRequest> testUser1ChannelSub( new RocketChatSubscribeChannelRequest( "AX8HDAKASKki6ZjDJwakuwFBdwjcSuan2n" ) );
mDDPApi->sendRequest( notifySubSubscription );
......@@ -143,7 +143,7 @@ void ApiCompatTests::testAddUserToChannel()
void ApiCompatTests::testBlockUser()
{
bool success = false;
QSharedPointer<RocketChatBlockUserRequest> blockRequest( new RocketChatBlockUserRequest( "azGA4Zy5ACRoBkn6KkX7dHQgXjJcwqaLSm", "azGA4Zy5ACRoBkn6K" ) );
QSharedPointer<RocketChatBlockUserRequest> blockRequest( new RocketChatBlockUserRequest( "AX8HDAKASKki6ZjDJwakuwFBdwjcSuan2n", "wakuwFBdwjcSuan2n" ) );
connect( mDDPApi, &MeteorDDP::messageReceived, [&]( QJsonObject pMessage ) {
if ( pMessage.contains( "collection" ) && pMessage["collection"] == "stream-notify-user" && pMessage.contains( "fields" ) ) {
QJsonObject fields = pMessage["fields"].toObject();
......@@ -155,7 +155,7 @@ void ApiCompatTests::testBlockUser()
if ( firstArg == "updated" ) {
QJsonObject data = args[1].toObject();
if ( data["rid"] == "azGA4Zy5ACRoBkn6KkX7dHQgXjJcwqaLSm" ) {
if ( data["rid"] == "AX8HDAKASKki6ZjDJwakuwFBdwjcSuan2n" ) {
if ( data.contains( "blocker" ) ) {
if ( data["blocker"].toBool() ) {
success = true;
......@@ -174,7 +174,7 @@ void ApiCompatTests::testBlockUser()
void ApiCompatTests::testUnBlockUser()
{
bool success = false;
QSharedPointer<RocketChatUnblockUserRequest> blockRequest( new RocketChatUnblockUserRequest( "azGA4Zy5ACRoBkn6KkX7dHQgXjJcwqaLSm", "azGA4Zy5ACRoBkn6K" ) );
QSharedPointer<RocketChatUnblockUserRequest> blockRequest( new RocketChatUnblockUserRequest( "AX8HDAKASKki6ZjDJwakuwFBdwjcSuan2n", "wakuwFBdwjcSuan2n" ) );
connect( mDDPApi, &MeteorDDP::messageReceived, [&]( QJsonObject pMessage ) {
if ( pMessage.contains( "collection" ) && pMessage["collection"] == "stream-notify-user" && pMessage.contains( "fields" ) ) {
QJsonObject fields = pMessage["fields"].toObject();
......@@ -187,7 +187,7 @@ void ApiCompatTests::testUnBlockUser()
if ( firstArg == "updated" ) {
QJsonObject data = args[1].toObject();
if ( data["rid"] == "azGA4Zy5ACRoBkn6KkX7dHQgXjJcwqaLSm" ) {
if ( data["rid"] == "AX8HDAKASKki6ZjDJwakuwFBdwjcSuan2n" ) {
if ( data.contains( "blocker" ) ) {
if ( !data["blocker"].toBool() ) {
success = true;
......@@ -212,7 +212,7 @@ void ApiCompatTests::testChangeUserPresenceDefault()
if ( pMessage.contains( "collection" ) && pMessage["collection"] == "users" && pMessage.contains( "fields" ) ) {
QJsonObject fields = pMessage["fields"].toObject();
if ( pMessage["id"].toString() == "KkX7dHQgXjJcwqaLSm" && fields.contains( "statusDefault" ) ) {
if ( pMessage["id"].toString() == "AX8HDAKASKki6ZjDJ" && fields.contains( "statusDefault" ) ) {
QString statusDefault = fields["statusDefault" ].toString();
if ( statusDefault == "away" ) {
......@@ -287,7 +287,7 @@ void ApiCompatTests::testSendTextMessage()
QJsonObject userObj = firstArg["u"].toObject();
QString userId = userObj["_id"].toString();
if ( rid == "azGA4Zy5ACRoBkn6KkX7dHQgXjJcwqaLSm" && msg == "testMessage1" && userId == mUserId ) {
if ( rid == "AX8HDAKASKki6ZjDJwakuwFBdwjcSuan2n" && msg == "testMessage1" && userId == mUserId ) {
success = true;
}
}
......@@ -295,7 +295,7 @@ void ApiCompatTests::testSendTextMessage()
}
} );
QJsonObject params;
params[QStringLiteral( "rid" )] = "azGA4Zy5ACRoBkn6KkX7dHQgXjJcwqaLSm";
params[QStringLiteral( "rid" )] = "AX8HDAKASKki6ZjDJwakuwFBdwjcSuan2n";
params[QStringLiteral( "msg" )] = "testMessage1";
QSharedPointer<DDPRequest> sendMessageRequest( new DDPMethodRequest( QStringLiteral( "sendMessage" ), {params} ) );
mDDPApi->sendRequest( sendMessageRequest );
......
File added
{"options":{},"indexes":[{"v":2,"key":{"_id":1},"name":"_id_","ns":"admin.system.version"}],"uuid":"6c14fea2be1a4a7c80ab9e5354afc9f1"}
\ No newline at end of file
{"options":{},"indexes":[{"v":2,"key":{"_id":1},"name":"_id_","ns":"meteor._raix_push_app_tokens"},{"v":2,"key":{"userId":1},"name":"userId_1","ns":"meteor._raix_push_app_tokens"}],"uuid":"ea0cc8ae836e43e581ee2ffde465d9f0"}
\ No newline at end of file
{"options":{},"indexes":[{"v":2,"key":{"_id":1},"name":"_id_","ns":"meteor._raix_push_notifications"},{"v":2,"key":{"createdAt":1},"name":"createdAt_1","ns":"meteor._raix_push_notifications"},{"v":2,"key":{"sent":1},"name":"sent_1","ns":"meteor._raix_push_notifications"},{"v":2,"key":{"sending":1},"name":"sending_1","ns":"meteor._raix_push_notifications"},{"v":2,"key":{"delayUntil":1},"name":"delayUntil_1","ns":"meteor._raix_push_notifications"}],"uuid":"5700004330fa4f37bf31bd3165cf3844"}
\ No newline at end of file
File added
{"options":{},"indexes":[{"v":2,"key":{"_id":1},"name":"_id_","ns":"meteor.instances"},{"v":2,"key":{"_updatedAt":1},"name":"_updatedAt_1","ns":"meteor.instances","expireAfterSeconds":60}],"uuid":"18e2003aff8342e3884d7528aa0e5618"}
\ No newline at end of file
{"options":{},"indexes":[{"v":2,"key":{"_id":1},"name":"_id_","ns":"meteor.meteor_accounts_loginServiceConfiguration"},{"v":2,"unique":true,"key":{"service":1},"name":"service_1","ns":"meteor.meteor_accounts_loginServiceConfiguration"}],"uuid":"ef1a775852c348c2b2cccf3e21df2c38"}
\ No newline at end of file
{"options":{},"indexes":[{"v":2,"key":{"_id":1},"name":"_id_","ns":"meteor.meteor_oauth_pendingCredentials"},{"v":2,"unique":true,"key":{"key":1},"name":"key_1","ns":"meteor.meteor_oauth_pendingCredentials"},{"v":2,"key":{"credentialSecret":1},"name":"credentialSecret_1","ns":"meteor.meteor_oauth_pendingCredentials"},{"v":2,"key":{"createdAt":1},"name":"createdAt_1","ns":"meteor.meteor_oauth_pendingCredentials"}],"uuid":"d55e893fe1854d9585366840025c7e39"}
\ No newline at end of file
{"options":{},"indexes":[{"v":2,"key":{"_id":1},"name":"_id_","ns":"meteor.meteor_oauth_pendingRequestTokens"},{"v":2,"unique":true,"key":{"key":1},"name":"key_1","ns":"meteor.meteor_oauth_pendingRequestTokens"},{"v":2,"key":{"createdAt":1},"name":"createdAt_1","ns":"meteor.meteor_oauth_pendingRequestTokens"}],"uuid":"31603056085c4046b9fa48972d370925"}
\ No newline at end of file
File added
{"options":{},"indexes":[{"v":2,"key":{"_id":1},"name":"_id_","ns":"meteor.migrations"}],"uuid":"d6032c8ec45e482d85502302c76f21f9"}
\ No newline at end of file
{"options":{},"indexes":[{"v":2,"key":{"_id":1},"name":"_id_","ns":"meteor.rocketchat__trash"},{"v":2,"key":{"collection":1},"name":"collection_1","ns":"meteor.rocketchat__trash"},{"v":2,"key":{"_deletedAt":1},"name":"_deletedAt_1","ns":"meteor.rocketchat__trash","expireAfterSeconds":2592000}],"uuid":"7085bce03dfa4a95beab12a747cccb3f"}
\ No newline at end of file
File added
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment