summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Kögl <stefan@skoegl.net>2015-11-03 20:00:48 +0100
committerStefan Kögl <stefan@skoegl.net>2015-11-03 20:00:48 +0100
commit2a02d21d7bf7e017376b3e6f08d38e71343f6b98 (patch)
tree90968f5262acd50308b3a40a7722473513a1dc8f
parent99bf6166a4a52317a1a18e30b09cc1214fb46921 (diff)
downloadpython-json-patch-2a02d21d7bf7e017376b3e6f08d38e71343f6b98.tar.gz
Add failing test for #40
-rwxr-xr-xtests.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/tests.py b/tests.py
index 24f3908..2572dc0 100755
--- a/tests.py
+++ b/tests.py
@@ -359,6 +359,13 @@ class MakePatchTestCase(unittest.TestCase):
res = patch.apply(src)
self.assertEqual(res, dst)
+ def test_issue40(self):
+ """ Tests an issue in _split_by_common_seq reported in #40 """
+
+ src = [8, 7, 2, 1, 0, 9, 4, 3, 5, 6]
+ dest = [7, 2, 1, 0, 9, 4, 3, 6, 5, 8]
+ patch = jsonpatch.make_patch(src, dest)
+
class InvalidInputTests(unittest.TestCase):