summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--test/Makefile.am2
-rw-r--r--test/data/dictref1byte.bplistbin0 -> 50 bytes
-rw-r--r--test/data/dictref2bytes.bplistbin0 -> 52 bytes
-rw-r--r--test/data/dictref3bytes.bplistbin0 -> 54 bytes
-rw-r--r--test/data/dictref4bytes.bplistbin0 -> 56 bytes
-rw-r--r--test/data/dictref5bytes.bplistbin0 -> 58 bytes
-rw-r--r--test/data/dictref6bytes.bplistbin0 -> 60 bytes
-rw-r--r--test/data/dictref7bytes.bplistbin0 -> 62 bytes
-rw-r--r--test/data/dictref8bytes.bplistbin0 -> 64 bytes
-rw-r--r--test/data/off1byte.bplistbin0 -> 50 bytes
-rw-r--r--test/data/off2bytes.bplistbin0 -> 53 bytes
-rw-r--r--test/data/off3bytes.bplistbin0 -> 56 bytes
-rw-r--r--test/data/off4bytes.bplistbin0 -> 59 bytes
-rw-r--r--test/data/off5bytes.bplistbin0 -> 62 bytes
-rw-r--r--test/data/off6bytes.bplistbin0 -> 65 bytes
-rw-r--r--test/data/off7bytes.bplistbin0 -> 68 bytes
-rw-r--r--test/data/off8bytes.bplistbin0 -> 71 bytes
-rw-r--r--test/data/offxml.plist8
-rwxr-xr-xtest/offsetsize.test12
-rwxr-xr-xtest/refsize.test12
20 files changed, 34 insertions, 0 deletions
diff --git a/test/Makefile.am b/test/Makefile.am
index aed3a58..29938f2 100644
--- a/test/Makefile.am
+++ b/test/Makefile.am
@@ -36,6 +36,8 @@ TESTS = \
amp.test \
invalid_tag.test \
cdata.test \
+ offsetsize.test \
+ refsize.test \
malformed_dict.test
EXTRA_DIST = $(TESTS) data/1.plist data/2.plist data/3.plist data/4.plist data/5.plist data/6.plist data/7.plist data/signed.plist data/signed.bplist data/unsigned.plist data/unsigned.bplist data/hex.plist data/order.bplist data/recursion.bplist data/entities.plist data/empty_keys.plist data/amp.plist data/invalid_tag.plist data/cdata.test data/malformed_dict.bplist
diff --git a/test/data/dictref1byte.bplist b/test/data/dictref1byte.bplist
new file mode 100644
index 0000000..c33d70b
--- /dev/null
+++ b/test/data/dictref1byte.bplist
Binary files differ
diff --git a/test/data/dictref2bytes.bplist b/test/data/dictref2bytes.bplist
new file mode 100644
index 0000000..2a5225f
--- /dev/null
+++ b/test/data/dictref2bytes.bplist
Binary files differ
diff --git a/test/data/dictref3bytes.bplist b/test/data/dictref3bytes.bplist
new file mode 100644
index 0000000..fb34258
--- /dev/null
+++ b/test/data/dictref3bytes.bplist
Binary files differ
diff --git a/test/data/dictref4bytes.bplist b/test/data/dictref4bytes.bplist
new file mode 100644
index 0000000..5845107
--- /dev/null
+++ b/test/data/dictref4bytes.bplist
Binary files differ
diff --git a/test/data/dictref5bytes.bplist b/test/data/dictref5bytes.bplist
new file mode 100644
index 0000000..6ced9de
--- /dev/null
+++ b/test/data/dictref5bytes.bplist
Binary files differ
diff --git a/test/data/dictref6bytes.bplist b/test/data/dictref6bytes.bplist
new file mode 100644
index 0000000..2ed5f34
--- /dev/null
+++ b/test/data/dictref6bytes.bplist
Binary files differ
diff --git a/test/data/dictref7bytes.bplist b/test/data/dictref7bytes.bplist
new file mode 100644
index 0000000..cbb9368
--- /dev/null
+++ b/test/data/dictref7bytes.bplist
Binary files differ
diff --git a/test/data/dictref8bytes.bplist b/test/data/dictref8bytes.bplist
new file mode 100644
index 0000000..ffb4292
--- /dev/null
+++ b/test/data/dictref8bytes.bplist
Binary files differ
diff --git a/test/data/off1byte.bplist b/test/data/off1byte.bplist
new file mode 100644
index 0000000..c33d70b
--- /dev/null
+++ b/test/data/off1byte.bplist
Binary files differ
diff --git a/test/data/off2bytes.bplist b/test/data/off2bytes.bplist
new file mode 100644
index 0000000..f080738
--- /dev/null
+++ b/test/data/off2bytes.bplist
Binary files differ
diff --git a/test/data/off3bytes.bplist b/test/data/off3bytes.bplist
new file mode 100644
index 0000000..a2f926b
--- /dev/null
+++ b/test/data/off3bytes.bplist
Binary files differ
diff --git a/test/data/off4bytes.bplist b/test/data/off4bytes.bplist
new file mode 100644
index 0000000..35897be
--- /dev/null
+++ b/test/data/off4bytes.bplist
Binary files differ
diff --git a/test/data/off5bytes.bplist b/test/data/off5bytes.bplist
new file mode 100644
index 0000000..9df03cd
--- /dev/null
+++ b/test/data/off5bytes.bplist
Binary files differ
diff --git a/test/data/off6bytes.bplist b/test/data/off6bytes.bplist
new file mode 100644
index 0000000..3d78a47
--- /dev/null
+++ b/test/data/off6bytes.bplist
Binary files differ
diff --git a/test/data/off7bytes.bplist b/test/data/off7bytes.bplist
new file mode 100644
index 0000000..150c277
--- /dev/null
+++ b/test/data/off7bytes.bplist
Binary files differ
diff --git a/test/data/off8bytes.bplist b/test/data/off8bytes.bplist
new file mode 100644
index 0000000..f01114e
--- /dev/null
+++ b/test/data/off8bytes.bplist
Binary files differ
diff --git a/test/data/offxml.plist b/test/data/offxml.plist
new file mode 100644
index 0000000..c3c1e10
--- /dev/null
+++ b/test/data/offxml.plist
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+ <key>A</key>
+ <string>B</string>
+</dict>
+</plist>
diff --git a/test/offsetsize.test b/test/offsetsize.test
new file mode 100755
index 0000000..d548d88
--- /dev/null
+++ b/test/offsetsize.test
@@ -0,0 +1,12 @@
+## -*- sh -*-
+
+set -e
+
+DATASRC=$top_srcdir/test/data
+TESTFILES="off1byte.bplist off2bytes.bplist off3bytes.bplist off4bytes.bplist off5bytes.bplist off6bytes.bplist off7bytes.bplist off8bytes.bplist"
+CMPFILE=offxml.plist
+
+for I in $TESTFILES; do
+ echo "* checking $I"
+ $top_builddir/test/plist_cmp $DATASRC/$I $DATASRC/$CMPFILE
+done
diff --git a/test/refsize.test b/test/refsize.test
new file mode 100755
index 0000000..379b7fb
--- /dev/null
+++ b/test/refsize.test
@@ -0,0 +1,12 @@
+## -*- sh -*-
+
+set -e
+
+DATASRC=$top_srcdir/test/data
+TESTFILES="dictref1byte.bplist dictref2bytes.bplist dictref3bytes.bplist dictref4bytes.bplist dictref5bytes.bplist dictref6bytes.bplist dictref7bytes.bplist dictref8bytes.bplist"
+CMPFILE=offxml.plist
+
+for I in $TESTFILES; do
+ echo "* checking $I"
+ $top_builddir/test/plist_cmp $DATASRC/$I $DATASRC/$CMPFILE
+done