@@ -172,7 +172,6 @@ auto AddTestCasesWizard::getMatchedPart(const QString &str, const QString &patte
172
172
QString regExp = ui->argumentList ->item (index, 1 )->text ();
173
173
174
174
for (int j = i; j < str.length (); j++) {
175
- #if (QT_VERSION >= QT_VERSION_CHECK(5, 15, 0))
176
175
regExp = QRegularExpression::anchoredPattern (regExp);
177
176
if (QRegularExpression (regExp).match (str.mid (i, j - i + 1 )).hasMatch ()) {
178
177
if (QRegularExpression (
@@ -184,15 +183,6 @@ auto AddTestCasesWizard::getMatchedPart(const QString &str, const QString &patte
184
183
break ;
185
184
}
186
185
}
187
- #else
188
- if (QRegExp (regExp).exactMatch (str.mid (i, j - i + 1 ))) {
189
- if (QRegExp (getFullRegExp (pattern.mid (pos + 3 ))).exactMatch (str.mid (j + 1 ))) {
190
- result[index] = str.mid (i, j - i + 1 );
191
- i = j;
192
- break ;
193
- }
194
- }
195
- #endif
196
186
}
197
187
pos += 2 ;
198
188
}
@@ -210,11 +200,7 @@ void AddTestCasesWizard::searchMatchedFiles() {
210
200
QString regExp = getFullRegExp (inputFilesPattern);
211
201
212
202
for (int i = 0 ; i < inputFiles.size (); i++) {
213
- #if QT_VERSION >= QT_VERSION_CHECK(5, 15, 0)
214
203
if (! QRegularExpression (QRegularExpression::anchoredPattern (regExp)).match (inputFiles[i]).hasMatch ())
215
- #else
216
- if (! QRegExp (regExp).exactMatch (inputFiles[i]))
217
- #endif
218
204
{
219
205
inputFiles.removeAt (i);
220
206
i--;
@@ -224,13 +210,9 @@ void AddTestCasesWizard::searchMatchedFiles() {
224
210
regExp = getFullRegExp (outputFilesPattern);
225
211
226
212
for (int i = 0 ; i < outputFiles.size (); i++) {
227
- #if QT_VERSION >= QT_VERSION_CHECK(5, 15, 0)
228
213
if (! QRegularExpression (QRegularExpression::anchoredPattern (regExp))
229
214
.match (outputFiles[i])
230
215
.hasMatch ())
231
- #else
232
- if (! QRegExp (regExp).exactMatch (outputFiles[i]))
233
- #endif
234
216
{
235
217
outputFiles.removeAt (i);
236
218
i--;
0 commit comments