mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-07-22 14:30:44 -04:00
Fix code formatting with new clang-format version
This commit is contained in:
parent
afe634d4f2
commit
e48ef80e9c
25 changed files with 91 additions and 178 deletions
|
@ -801,32 +801,23 @@ void TestGui::testPasswordEntryEntropy_data()
|
|||
QTest::addColumn<QString>("password");
|
||||
QTest::addColumn<QString>("expectedStrengthLabel");
|
||||
|
||||
QTest::newRow("Empty password") << ""
|
||||
<< "Password Quality: Poor";
|
||||
QTest::newRow("Empty password") << "" << "Password Quality: Poor";
|
||||
|
||||
QTest::newRow("Well-known password") << "hello"
|
||||
<< "Password Quality: Poor";
|
||||
QTest::newRow("Well-known password") << "hello" << "Password Quality: Poor";
|
||||
|
||||
QTest::newRow("Password composed of well-known words.") << "helloworld"
|
||||
<< "Password Quality: Poor";
|
||||
QTest::newRow("Password composed of well-known words.") << "helloworld" << "Password Quality: Poor";
|
||||
|
||||
QTest::newRow("Password composed of well-known words with number.") << "password1"
|
||||
<< "Password Quality: Poor";
|
||||
QTest::newRow("Password composed of well-known words with number.") << "password1" << "Password Quality: Poor";
|
||||
|
||||
QTest::newRow("Password out of small character space.") << "D0g.................."
|
||||
<< "Password Quality: Poor";
|
||||
QTest::newRow("Password out of small character space.") << "D0g.................." << "Password Quality: Poor";
|
||||
|
||||
QTest::newRow("XKCD, easy substitutions.") << "Tr0ub4dour&3"
|
||||
<< "Password Quality: Poor";
|
||||
QTest::newRow("XKCD, easy substitutions.") << "Tr0ub4dour&3" << "Password Quality: Poor";
|
||||
|
||||
QTest::newRow("XKCD, word generator.") << "correcthorsebatterystaple"
|
||||
<< "Password Quality: Weak";
|
||||
QTest::newRow("XKCD, word generator.") << "correcthorsebatterystaple" << "Password Quality: Weak";
|
||||
|
||||
QTest::newRow("Random characters, medium length.") << "YQC3kbXbjC652dTDH"
|
||||
<< "Password Quality: Good";
|
||||
QTest::newRow("Random characters, medium length.") << "YQC3kbXbjC652dTDH" << "Password Quality: Good";
|
||||
|
||||
QTest::newRow("Random characters, long.") << "Bs5ZFfthWzR8DGFEjaCM6bGqhmCT4km"
|
||||
<< "Password Quality: Excellent";
|
||||
QTest::newRow("Random characters, long.") << "Bs5ZFfthWzR8DGFEjaCM6bGqhmCT4km" << "Password Quality: Excellent";
|
||||
|
||||
QTest::newRow("Long password using Zxcvbn chunk estimation")
|
||||
<< "quintet-tamper-kinswoman-humility-vengeful-haven-tastiness-aspire-widget-ipad-cussed-reaffirm-ladylike-"
|
||||
|
@ -1544,18 +1535,14 @@ void TestGui::testSaveBackupPath_data()
|
|||
|
||||
QTest::newRow("Absolute backup path") << tmpFile.fileName() << tmpFile.fileName();
|
||||
// relative paths should be resolved to database parent directory
|
||||
QTest::newRow("Relative backup path (implicit)") << "other_dir/test.old.kdbx"
|
||||
<< "other_dir/test.old.kdbx";
|
||||
QTest::newRow("Relative backup path (explicit)") << "./other_dir2/test2.old.kdbx"
|
||||
<< "other_dir2/test2.old.kdbx";
|
||||
QTest::newRow("Relative backup path (implicit)") << "other_dir/test.old.kdbx" << "other_dir/test.old.kdbx";
|
||||
QTest::newRow("Relative backup path (explicit)") << "./other_dir2/test2.old.kdbx" << "other_dir2/test2.old.kdbx";
|
||||
|
||||
QTest::newRow("Path with placeholders") << "{DB_FILENAME}.old.kdbx"
|
||||
<< "KeePassXC.old.kdbx";
|
||||
QTest::newRow("Path with placeholders") << "{DB_FILENAME}.old.kdbx" << "KeePassXC.old.kdbx";
|
||||
// empty path should be replaced with default pattern
|
||||
QTest::newRow("Empty path") << QString("") << config()->getDefault(Config::BackupFilePathPattern).toString();
|
||||
// {DB_FILENAME} should be replaced with database filename
|
||||
QTest::newRow("") << "{DB_FILENAME}_.old.kdbx"
|
||||
<< "{DB_FILENAME}_.old.kdbx";
|
||||
QTest::newRow("") << "{DB_FILENAME}_.old.kdbx" << "{DB_FILENAME}_.old.kdbx";
|
||||
}
|
||||
|
||||
void TestGui::testSaveBackupPath()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue