Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
PIM
PIM Data Exporter
Commits
b2a82772
Commit
b2a82772
authored
May 25, 2020
by
Laurent Montel
Browse files
Fix import akregator autotest
parent
dd25a544
Changes
4
Hide whitespace changes
Inline
Side-by-side
core/autotests/akregator/data/import/akregatorconfig/list.txt
0 → 100644
View file @
b2a82772
core/autotests/akregator/data/import/akregatorresource/list.txt
0 → 100644
View file @
b2a82772
core/autotests/akregator/importakregatorjobinterfacetest.cpp
View file @
b2a82772
...
...
@@ -51,22 +51,28 @@ ImportAkregatorJobInterfaceTest::ImportAkregatorJobInterfaceTest(QObject *parent
{
}
void
ImportAkregatorJobInterfaceTest
::
importCalendarConfig_data
()
void
ImportAkregatorJobInterfaceTest
::
importAkegator_data
()
{
QTest
::
addColumn
<
QString
>
(
"zipFilePath"
);
QTest
::
addColumn
<
QString
>
(
"testPath"
);
QTest
::
addColumn
<
Utils
::
StoredTypes
>
(
"options"
);
const
QByteArray
pathConfig
(
QByteArray
(
PIMDATAEXPORTER_DIR
)
+
"/import/"
);
QTest
::
newRow
(
"test1"
)
<<
QString
::
fromLatin1
(
pathConfig
)
<<
QStringLiteral
(
"/test1/"
);
Utils
::
StoredTypes
options
=
{
Utils
::
StoredType
::
Config
};
QTest
::
newRow
(
"test1"
)
<<
QString
::
fromLatin1
(
pathConfig
)
<<
QStringLiteral
(
"/test1/"
)
<<
options
;
options
=
{
Utils
::
StoredType
::
Config
|
Utils
::
StoredType
::
Resources
};
QTest
::
newRow
(
"test1resource"
)
<<
QString
::
fromLatin1
(
pathConfig
)
<<
QStringLiteral
(
"/test1resource/"
)
<<
options
;
}
void
ImportAkregatorJobInterfaceTest
::
import
CalendarConfig
()
void
ImportAkregatorJobInterfaceTest
::
import
Akegator
()
{
QFETCH
(
QString
,
zipFilePath
);
QFETCH
(
QString
,
testPath
);
QFETCH
(
Utils
::
StoredTypes
,
options
);
TestImportFile
*
file
=
new
TestImportFile
(
zipFilePath
+
testPath
,
this
);
file
->
setPathConfig
(
zipFilePath
+
testPath
);
file
->
setExtractPath
(
QDir
::
tempPath
()
+
testPath
);
ImportAkregatorJobInterfaceTestImpl
*
impl
=
new
ImportAkregatorJobInterfaceTestImpl
(
this
,
{
Utils
::
StoredType
::
Config
}
,
file
->
archiveStorage
(),
1
);
ImportAkregatorJobInterfaceTestImpl
*
impl
=
new
ImportAkregatorJobInterfaceTestImpl
(
this
,
options
,
file
->
archiveStorage
(),
1
);
file
->
setAbstractImportExportJob
(
impl
);
file
->
start
();
delete
impl
;
...
...
core/autotests/akregator/importakregatorjobinterfacetest.h
View file @
b2a82772
...
...
@@ -43,8 +43,8 @@ public:
explicit
ImportAkregatorJobInterfaceTest
(
QObject
*
parent
=
nullptr
);
~
ImportAkregatorJobInterfaceTest
()
=
default
;
private
Q_SLOTS
:
void
import
CalendarConfig
();
void
import
CalendarConfig_data
();
void
import
Akegator_data
();
void
import
Akegator
();
};
#endif // IMPORTAKREGATORJOBINTERFACETEST_H
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment