diff options
author | Taylor R Campbell <campbell+paredit@mumble.net> | 2020-11-30 16:06:29 +0000 |
---|---|---|
committer | Taylor R Campbell <campbell+paredit@mumble.net> | 2020-11-30 16:06:29 +0000 |
commit | 84e8ccd2ae3e2d9033533cdd4ce69fb254b20067 (patch) | |
tree | df349265dec177ebb22b164c3f73e930b63db8f0 | |
parent | c6300b9cbe01570f6a64ef7b46dffd557ecddfd1 (diff) |
Add some examples of slurping edge cases that we should handle.
Derived from suggestion by Jonathon McKitrick <jmckitrick@gmail.com>.
-rw-r--r-- | test.el | 33 |
1 files changed, 31 insertions, 2 deletions
@@ -1287,7 +1287,21 @@ Four arguments: the paredit command, the text of the buffer ("(\"x\"|) y" "(\"x\"| y)") ("(\"x\")| y" error) ("(\"x\") |y" error) - ("(\"x\") y|" error))) + ("(\"x\") y|" error) + ("|(x)y" error) + (xfail "(|x)y" "(|x y)" error) + (xfail"(x|)y" "(x| y)" error) + ("(x)|y" error) + ("(x)y|" error) + ("|(x) ;c\ny" error) + (xfail "(|x) ;c\ny" "(|x ;c\n y)" error) + (xfail "(x|) ;c\ny" "(x| ;c\n y)" error) + ("(x)| ;c\ny" error) + ("(x) |;c\ny" error) + ("(x) ;|c\ny" error) + ("(x) ;c|\ny" error) + ("(x) ;c\n|y" error) + ("(x) ;c\ny|" error))) (paredit-test 'paredit-backward-slurp-sexp '(("|" error) @@ -1352,7 +1366,22 @@ Four arguments: the paredit command, the text of the buffer ("x (\"|y\")" "(x \"|y\")" "(\"x |y\")") ("x (\"y|\")" "(x \"y|\")" "(\"x y|\")") ("x (\"y\"|)" "(x \"y\"|)") - ("x (\"y\")|" error))) + ("x (\"y\")|" error) + ("|x(y)" error) + ("x|(y)" error) + (xfail "x(|y)" "(x |y)" error) + (xfail "x(y|)" "(x y|)" error) + ("x(y)|" error) + ("|x ;c\n(y)" error) + ("x| ;c\n(y)" error) + ("x | ;c\n(y)" error) + ("x |;c\n(y)" error) + ("x ;|c\n(y)" error) + ("x ;c|\n(y)" error) + ("x ;c\n|(y)" error) + (xfail "x ;c\n(|y)" "(x ;c\n |y)" error) + (xfail "x ;c\n(y|)" "(x ;c\n y|)" error) + ("x ;c\n(y)|" error))) (let ((current-prefix-arg 2)) (paredit-test 'paredit-forward-slurp-sexp |