Skip to content

Commit

Permalink
adapt test to expect no decimals for unit bytes (#10594)
Browse files Browse the repository at this point in the history
  • Loading branch information
meigelb committed Apr 21, 2024
1 parent 3913280 commit 8b5aa94
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tests/TestTools.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ void TestTools::testHumanReadableFileSize()
constexpr auto kibibyte = 1024u;
using namespace Tools;

QCOMPARE(createDecimal("1", "00", "B"), humanReadableFileSize(1));
QCOMPARE(QString("1 B"), humanReadableFileSize(1));
QCOMPARE(createDecimal("1", "00", "KiB"), humanReadableFileSize(kibibyte));
QCOMPARE(createDecimal("1", "00", "MiB"), humanReadableFileSize(kibibyte * kibibyte));
QCOMPARE(createDecimal("1", "00", "GiB"), humanReadableFileSize(kibibyte * kibibyte * kibibyte));
Expand Down

0 comments on commit 8b5aa94

Please sign in to comment.