style and whitespace
This commit is contained in:
parent
0e4e04ee36
commit
ab49c3379b
1 changed files with 5 additions and 4 deletions
|
@ -820,7 +820,7 @@ surrogates_test_() ->
|
||||||
good_characters_test_() ->
|
good_characters_test_() ->
|
||||||
[
|
[
|
||||||
{"acceptable codepoints",
|
{"acceptable codepoints",
|
||||||
?_assert(check_good(good(), []))
|
?_assert(check_good(good()))
|
||||||
},
|
},
|
||||||
{"acceptable codepoints - json_escape",
|
{"acceptable codepoints - json_escape",
|
||||||
?_assert(check_good(good(), [json_escape]))
|
?_assert(check_good(good(), [json_escape]))
|
||||||
|
@ -832,7 +832,7 @@ good_characters_test_() ->
|
||||||
?_assert(check_good(good(), [json_escape, loose_unicode]))
|
?_assert(check_good(good(), [json_escape, loose_unicode]))
|
||||||
},
|
},
|
||||||
{"acceptable extended",
|
{"acceptable extended",
|
||||||
?_assert(check_good(good_extended(), []))
|
?_assert(check_good(good_extended()))
|
||||||
},
|
},
|
||||||
{"acceptable extended - json_escape",
|
{"acceptable extended - json_escape",
|
||||||
?_assert(check_good(good_extended(), [json_escape]))
|
?_assert(check_good(good_extended(), [json_escape]))
|
||||||
|
@ -883,13 +883,14 @@ check_bad(List) ->
|
||||||
|
|
||||||
|
|
||||||
check_replaced(List) ->
|
check_replaced(List) ->
|
||||||
[] == lists:dropwhile(fun({_, [{string, <<16#fffd/utf8>>}|_]}) -> true
|
[] == lists:dropwhile(fun({_, [{string, <<16#fffd/utf8>>}|_]}) -> true ; (_) -> false
|
||||||
; (_) -> false
|
|
||||||
end,
|
end,
|
||||||
check(List, [loose_unicode], [])
|
check(List, [loose_unicode], [])
|
||||||
).
|
).
|
||||||
|
|
||||||
|
|
||||||
|
check_good(List) -> check_good(List, []).
|
||||||
|
|
||||||
check_good(List, Opts) ->
|
check_good(List, Opts) ->
|
||||||
[] == lists:dropwhile(fun({_, [{string, _}|_]}) -> true ; (_) -> false end,
|
[] == lists:dropwhile(fun({_, [{string, _}|_]}) -> true ; (_) -> false end,
|
||||||
check(List, Opts, [])
|
check(List, Opts, [])
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue