Improved initial connection check

This commit is contained in:
Alexey Romanov
2014-10-23 00:06:22 +04:00
parent 174d3cbe8f
commit a4f1d990a0
3 changed files with 95 additions and 79 deletions

View File

@@ -344,6 +344,16 @@ issue23() ->
?assertEqual([SingleStmtResult, SingleStmtResult], ScriptResult),
sqlite3:close(issue23).
non_db_file_test() ->
process_flag(trap_exit, true),
?assertMatch({error, _},
sqlite3:start_link(bad_file, [{file, "/"}])),
receive
{'EXIT', _, _} -> ok;
_ -> ?assert(false)
end.
% create, read, update, delete
%%====================================================================
%% Internal functions