Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
libksieve
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
PIM
libksieve
Commits
08063cdd
Commit
08063cdd
authored
May 19, 2017
by
Laurent Montel
😁
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Continue to implement regexpeditorlineedit
parent
f44663ea
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
21 additions
and
4 deletions
+21
-4
src/ksieveui/autocreatescripts/autotests/regexpeditorlineedittest.cpp
.../autocreatescripts/autotests/regexpeditorlineedittest.cpp
+16
-0
src/ksieveui/autocreatescripts/autotests/regexpeditorlineedittest.h
...ui/autocreatescripts/autotests/regexpeditorlineedittest.h
+2
-0
src/ksieveui/autocreatescripts/sieveconditions/widgets/regexpeditorlineedit.cpp
...escripts/sieveconditions/widgets/regexpeditorlineedit.cpp
+3
-4
No files found.
src/ksieveui/autocreatescripts/autotests/regexpeditorlineedittest.cpp
View file @
08063cdd
...
...
@@ -40,4 +40,20 @@ void RegexpEditorLineEditTest::shouldHaveDefaultValue()
QCOMPARE
(
mainLayout
->
margin
(),
0
);
}
void
RegexpEditorLineEditTest
::
shouldChangeValue_data
()
{
QTest
::
addColumn
<
QString
>
(
"input"
);
QTest
::
newRow
(
"empty"
)
<<
QString
();
QTest
::
newRow
(
"test1"
)
<<
QStringLiteral
(
"foo"
);
}
void
RegexpEditorLineEditTest
::
shouldChangeValue
()
{
QFETCH
(
QString
,
input
);
KSieveUi
::
RegexpEditorLineEdit
w
;
w
.
setCode
(
input
);
QCOMPARE
(
w
.
code
(),
input
);
}
QTEST_MAIN
(
RegexpEditorLineEditTest
)
src/ksieveui/autocreatescripts/autotests/regexpeditorlineedittest.h
View file @
08063cdd
...
...
@@ -30,6 +30,8 @@ public:
~
RegexpEditorLineEditTest
()
=
default
;
private
Q_SLOTS
:
void
shouldHaveDefaultValue
();
void
shouldChangeValue
();
void
shouldChangeValue_data
();
};
#endif // REGEXPEDITORLINEEDITTEST_H
src/ksieveui/autocreatescripts/sieveconditions/widgets/regexpeditorlineedit.cpp
View file @
08063cdd
...
...
@@ -41,16 +41,15 @@ RegexpEditorLineEdit::~RegexpEditorLineEdit()
void
RegexpEditorLineEdit
::
switchToRegexpEditorLineEdit
()
{
//
TODO
//
Nothing here
}
void
KSieveUi
::
RegexpEditorLineEdit
::
setCode
(
const
QString
&
str
)
{
//TODO
mLineEdit
->
setText
(
str
);
}
QString
KSieveUi
::
RegexpEditorLineEdit
::
code
()
const
{
//TODO
return
{};
return
mLineEdit
->
text
();
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a 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