You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
24 lines
535 B
C++
24 lines
535 B
C++
// SPDX-License-Identifier: GPL-2.0-or-later
|
|
|
|
#include "utils.hpp"
|
|
|
|
#include <gtest/gtest.h>
|
|
|
|
using namespace Exiv2::Internal;
|
|
|
|
TEST(stringUtils, startsWithReturnsTrue) {
|
|
ASSERT_TRUE(startsWith("Exiv2 rocks", "Exiv2"));
|
|
}
|
|
|
|
TEST(stringUtils, startsWithReturnsFlase) {
|
|
ASSERT_FALSE(startsWith("Exiv2 rocks", "exiv2"));
|
|
}
|
|
|
|
TEST(stringUtils, upperTransformStringToUpperCase) {
|
|
ASSERT_EQ("EXIV2 ROCKS", upper("Exiv2 rocks"));
|
|
}
|
|
|
|
TEST(stringUtils, lowerTransformStringToLowerCase) {
|
|
ASSERT_EQ("exiv2 rocks", lower("EXIV2 ROCKS"));
|
|
}
|