summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2021-03-02 21:00:57 -0500
committerMatthias Clasen <mclasen@redhat.com>2021-03-02 21:27:12 -0500
commit2ec635ae28261418313156e21b1eeed42d28f056 (patch)
treee646f10f9cc9cdc779c0fc8f0e683f4fbfa588b3
parent283f646dd7ac44d0c0d7b12d15bd2f6a4346c8f5 (diff)
downloadpango-markup-parse-fixes.tar.gz
markup tests: Add tests for parsing accelsmarkup-parse-fixes
Add tests that test some of the corner cases handled in the previous commit.
-rw-r--r--tests/markups/valid-13.expected21
-rw-r--r--tests/markups/valid-13.markup1
-rw-r--r--tests/markups/valid-14.expected24
-rw-r--r--tests/markups/valid-14.markup1
-rw-r--r--tests/markups/valid-15.expected10
-rw-r--r--tests/markups/valid-15.markup0
-rw-r--r--tests/meson.build3
7 files changed, 60 insertions, 0 deletions
diff --git a/tests/markups/valid-13.expected b/tests/markups/valid-13.expected
new file mode 100644
index 00000000..c63a71c4
--- /dev/null
+++ b/tests/markups/valid-13.expected
@@ -0,0 +1,21 @@
+abc def
+
+
+---
+
+range 0 4
+range 4 5
+[4,5]underline=3
+range 5 2147483647
+
+
+---
+
+[0:4] (null) Normal
+[4:5] (null) Normal
+[5:2147483647] (null) Normal
+
+
+---
+
+d \ No newline at end of file
diff --git a/tests/markups/valid-13.markup b/tests/markups/valid-13.markup
new file mode 100644
index 00000000..45ccaefb
--- /dev/null
+++ b/tests/markups/valid-13.markup
@@ -0,0 +1 @@
+<markup>abc _def</markup>
diff --git a/tests/markups/valid-14.expected b/tests/markups/valid-14.expected
new file mode 100644
index 00000000..4aa87977
--- /dev/null
+++ b/tests/markups/valid-14.expected
@@ -0,0 +1,24 @@
+abc def _x_
+
+
+---
+
+range 0 1
+[0,1]underline=3
+range 1 4
+range 4 5
+[4,5]underline=3
+range 5 2147483647
+
+
+---
+
+[0:1] (null) Normal
+[1:4] (null) Normal
+[4:5] (null) Normal
+[5:2147483647] (null) Normal
+
+
+---
+
+a \ No newline at end of file
diff --git a/tests/markups/valid-14.markup b/tests/markups/valid-14.markup
new file mode 100644
index 00000000..52466786
--- /dev/null
+++ b/tests/markups/valid-14.markup
@@ -0,0 +1 @@
+<markup>_abc _def __x_</markup>
diff --git a/tests/markups/valid-15.expected b/tests/markups/valid-15.expected
new file mode 100644
index 00000000..77032f87
--- /dev/null
+++ b/tests/markups/valid-15.expected
@@ -0,0 +1,10 @@
+
+
+---
+
+range 0 2147483647
+
+
+---
+
+[0:2147483647] (null) Normal
diff --git a/tests/markups/valid-15.markup b/tests/markups/valid-15.markup
new file mode 100644
index 00000000..e69de29b
--- /dev/null
+++ b/tests/markups/valid-15.markup
diff --git a/tests/meson.build b/tests/meson.build
index bdccd55d..ccd2541e 100644
--- a/tests/meson.build
+++ b/tests/meson.build
@@ -91,6 +91,9 @@ test_markups_data = [
'markups/valid-10',
'markups/valid-11',
'markups/valid-12',
+ 'markups/valid-13',
+ 'markups/valid-14',
+ 'markups/valid-15',
]
test_breaks_data = [