summaryrefslogtreecommitdiffstats
path: root/testfiles/src/sp-glyph-kerning-test.cpp
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-13 11:50:49 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-13 11:50:49 +0000
commitc853ffb5b2f75f5a889ed2e3ef89b818a736e87a (patch)
tree7d13a0883bb7936b84d6ecdd7bc332b41ed04bee /testfiles/src/sp-glyph-kerning-test.cpp
parentInitial commit. (diff)
downloadinkscape-c853ffb5b2f75f5a889ed2e3ef89b818a736e87a.tar.xz
inkscape-c853ffb5b2f75f5a889ed2e3ef89b818a736e87a.zip
Adding upstream version 1.3+ds.upstream/1.3+dsupstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'testfiles/src/sp-glyph-kerning-test.cpp')
-rw-r--r--testfiles/src/sp-glyph-kerning-test.cpp26
1 files changed, 26 insertions, 0 deletions
diff --git a/testfiles/src/sp-glyph-kerning-test.cpp b/testfiles/src/sp-glyph-kerning-test.cpp
new file mode 100644
index 0000000..2c737ee
--- /dev/null
+++ b/testfiles/src/sp-glyph-kerning-test.cpp
@@ -0,0 +1,26 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
+/** @file
+ * SPGlyphKerning test
+ *//*
+ *
+ * Authors:
+ * Cosmin Dancu
+ *
+ * Copyright (C) 2020 Authors
+ *
+ * Released under GNU GPL version 2 or later, read the file 'COPYING' for more information
+ */
+
+#include <gtest/gtest.h>
+#include <src/object/sp-glyph-kerning.h>
+
+TEST(SPGlyphKerningTest, EmptyGlyphNamesDoNotContainAnything) {
+ GlyphNames empty_glyph_names(nullptr);
+ ASSERT_FALSE(empty_glyph_names.contains("foo"));
+}
+
+TEST(SPGlyphKerningTest, GlyphNamesContainEachName) {
+ GlyphNames glyph_names("name1 name2");
+ ASSERT_TRUE(glyph_names.contains("name1"));
+ ASSERT_TRUE(glyph_names.contains("name2"));
+}