aboutsummaryrefslogtreecommitdiffstats
path: root/lib/xmerl/test/xmerl_sax_stream_SUITE.erl
diff options
context:
space:
mode:
authorLars Thorsen <[email protected]>2017-06-05 10:23:09 +0200
committerLars Thorsen <[email protected]>2017-06-05 10:23:09 +0200
commit3cfd0ee2fc1edb9b6c613d8efeac2fdc51b3e4ba (patch)
tree87ddf34e763c39250d394564c23c169fc612ce25 /lib/xmerl/test/xmerl_sax_stream_SUITE.erl
parent5b014a2d416f8a18fcd17c031d680a32bc6473d8 (diff)
parent645371eb3a5cdcdbf73bde2ec906181ec701e1cf (diff)
downloadotp-3cfd0ee2fc1edb9b6c613d8efeac2fdc51b3e4ba.tar.gz
otp-3cfd0ee2fc1edb9b6c613d8efeac2fdc51b3e4ba.tar.bz2
otp-3cfd0ee2fc1edb9b6c613d8efeac2fdc51b3e4ba.zip
Merge branch 'maint'
Conflicts: OTP_VERSION erts/vsn.mk
Diffstat (limited to 'lib/xmerl/test/xmerl_sax_stream_SUITE.erl')
-rw-r--r--lib/xmerl/test/xmerl_sax_stream_SUITE.erl17
1 files changed, 16 insertions, 1 deletions
diff --git a/lib/xmerl/test/xmerl_sax_stream_SUITE.erl b/lib/xmerl/test/xmerl_sax_stream_SUITE.erl
index a306eb66a2..7315f67374 100644
--- a/lib/xmerl/test/xmerl_sax_stream_SUITE.erl
+++ b/lib/xmerl/test/xmerl_sax_stream_SUITE.erl
@@ -40,7 +40,8 @@ all() ->
[
one_document,
two_documents,
- one_document_and_junk
+ one_document_and_junk,
+ end_of_stream
].
%%----------------------------------------------------------------------
@@ -62,6 +63,9 @@ end_per_testcase(_Func, _Config) ->
%%----------------------------------------------------------------------
%% Tests
%%----------------------------------------------------------------------
+
+%%----------------------------------------------------------------------
+%% Send One doc over stream
one_document(Config) ->
Port = 11111,
@@ -107,6 +111,8 @@ one_document(Config) ->
end,
ok.
+%%----------------------------------------------------------------------
+%% Send Two doc over stream
two_documents(Config) ->
Port = 11111,
@@ -152,6 +158,8 @@ two_documents(Config) ->
end,
ok.
+%%----------------------------------------------------------------------
+%% Send one doc and then junk on stream
one_document_and_junk(Config) ->
Port = 11111,
@@ -196,6 +204,13 @@ one_document_and_junk(Config) ->
ct:fail("Timeout")
end,
ok.
+
+%%----------------------------------------------------------------------
+%% Test of continuation when end of stream
+end_of_stream(Config) ->
+ Stream = <<"<?xml version=\"1.0\" encoding=\"utf-8\"?><a>hej</a>">>,
+ {ok, undefined, <<>>} = xmerl_sax_parser:stream(Stream, []),
+ ok.
%%----------------------------------------------------------------------
%% Utility functions