Debian Codegraph @

tests/online-accounts/OnlineAccounts/tst_authentication_data/tst_authentication_data.cpp

raw symbols SCIP
1 /*
2 * This file is part of libOnlineAccounts
3 *
4 * Copyright (C) 2015 Canonical Ltd.
5 *
6 * Contact: Alberto Mardegan <[email protected]>
7 *
8 * This program is free software: you can redistribute it and/or modify it
9 * under the terms of the GNU Lesser General Public License version 3, as
10 * published by the Free Software Foundation.
11 *
12 * This program is distributed in the hope that it will be useful, but
13 * WITHOUT ANY WARRANTY; without even the implied warranties of
14 * MERCHANTABILITY, SATISFACTORY QUALITY, or FITNESS FOR A PARTICULAR
15 * PURPOSE. See the GNU Lesser General Public License for more details.
16 *
17 * You should have received a copy of the GNU Lesser General Public License
18 * along with this program. If not, see <http://www.gnu.org/licenses/>.
19 */
20
21 #include <QObject>
22 #include <QTest>
23 #include <LomiriOnlineAccounts/authentication_data.h>cxx . . $ `<file>/online-accounts/lib/qt/LomiriOnlineAccounts/authentication_data.h`/
24
25 using namespace OnlineAccounts;
26
27 class AuthenticationDataTestcxx . . $ AuthenticationDataTest# : public QObjectcxx . . $ QObject#
28 {
29 Q_OBJECTcxx . . $ `<external>/1208926524888476972/qobjectdefs.h:170:9`!
30
31 private Q_SLOTScxx . . $ `<external>/1208926524888476972/qobjectdefs.h:92:10`!:
32 void testDatacxx . . $ AuthenticationDataTest#testData(49f6e7a06ebc5aa8).();
33 };
34
35 void AuthenticationDataTestcxx . . $ AuthenticationDataTest#::testDatacxx . . $ AuthenticationDataTest#testData(49f6e7a06ebc5aa8).()
36 {
37 OAuth2Datacxx . . $ OnlineAccounts/OAuth2Data# oauth2cxx . . $ OnlineAccounts/OAuth2Data#OAuth2Data(49f6e7a06ebc5aa8).;
38
39 oauth2.setClientIdcxx . . $ OnlineAccounts/OAuth2Data#setClientId(45672f3c6961a244).("client"cxx . . $ QByteArray#QByteArray(34d26762b42c433a).);
40 QCOMPAREcxx . . $ `<external>/8602788698586413231/qtestcase.h:86:9`!(oauth2.clientId(), QByteArray("client"));
41
42 oauth2.setInteractivecxx . . $ OnlineAccounts/AuthenticationData#setInteractive(b45ddcbc8423892c).(false);
43 QCOMPAREcxx . . $ `<external>/8602788698586413231/qtestcase.h:86:9`!(oauth2.interactive(), false);
44
45 OAuth2Datacxx . . $ OnlineAccounts/OAuth2Data# copy = oauth2;
46 QCOMPAREcxx . . $ `<external>/8602788698586413231/qtestcase.h:86:9`!(copy.clientId(), QByteArray("client"));
47 QCOMPAREcxx . . $ `<external>/8602788698586413231/qtestcase.h:86:9`!(copy.interactive(), false);
48
49 oauth2.setClientIdcxx . . $ OnlineAccounts/OAuth2Data#setClientId(45672f3c6961a244).("client-changed"cxx . . $ QByteArray#QByteArray(34d26762b42c433a).);
50 QCOMPAREcxx . . $ `<external>/8602788698586413231/qtestcase.h:86:9`!(oauth2.clientId(), QByteArray("client-changed"));
51 QCOMPAREcxx . . $ `<external>/8602788698586413231/qtestcase.h:86:9`!(copy.clientId(), QByteArray("client"));
52
53 /* As dictionary */
54 QVariantMapcxx . . $ QVariantMap# expectedParameterscxx . . $ QMap#QMap(ced63f7c635d850d).;
55 expectedParameters.insertcxx . . $ QMap#insert(929a1ed410fe8423).("ClientId"cxx . . $ QString#QString(85c52e162fed56f9)., QByteArraycxx . . $ QVariant#QVariant(45672f3c6961a244).("client-changed"));
56 QCOMPAREcxx . . $ `<external>/8602788698586413231/qtestcase.h:86:9`!(oauth2.parameters(), expectedParameters);
57
58 QVariantMapcxx . . $ QVariantMap# parameterscxx . . $ QMap#QMap(ced63f7c635d850d).;
59 parameters.insertcxx . . $ QMap#insert(929a1ed410fe8423).("UnknownKey"cxx . . $ QString#QString(85c52e162fed56f9)., "some value"cxx . . $ QVariant#QVariant(85c52e162fed56f9).);
60 parameters.insertcxx . . $ QMap#insert(929a1ed410fe8423).("Hello"cxx . . $ QString#QString(85c52e162fed56f9)., "World"cxx . . $ QVariant#QVariant(85c52e162fed56f9).);
61 oauth2.setParameterscxx . . $ OnlineAccounts/AuthenticationData#setParameters(3e95df3e31f2cce8).(parameters);
62 QCOMPAREcxx . . $ `<external>/8602788698586413231/qtestcase.h:86:9`!(oauth2.parameters(), parameters);
63 }
64
65 QTEST_MAINcxx . . $ `<external>/4204159469433502174/qtest.h:508:9`!(AuthenticationDataTest)
66 #include "tst_authentication_data.moc"cxx . . $ `<file>/build/tests/online-accounts/OnlineAccounts/tst_authentication_data/tst_authentication_data_autogen/include/tst_authentication_data.moc`/