aboutsummaryrefslogtreecommitdiffstats
path: root/lib/odbc/test/odbc.dynspec
blob: bb15edceed96c30da6d7debff3e328386be23351 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
%% -*- erlang -*-
%% You can test this file using this command.
%%    file:script("odbc.dynspec", [{'Os',"Unix"}]).

Exists =
fun() ->
	case code:lib_dir(odbc) of
	    {error,bad_name} ->
		false;
	    P ->
		%% Make sure that the odbc directory really
		%% contains the application (and not only documentation).
		case filelib:is_file(filename:join(P, "ebin/odbc.beam")) of
		    false -> false;
		    true ->
			%% We know that we don't have any odbc libraries
			%% installed on this computer.
			{ok,Host} = inet:gethostname(),
			Host =/= "netsim200"
		end
	end
end,
case Exists() of
    false ->
	NoOdbc = "No odbc application",
	[{skip, {odbc_connect_SUITE, NoOdbc}},
	 {skip, {odbc_data_type_SUITE, NoOdbc}},
	 {skip, {odbc_query_SUITE, NoOdbc}}];
    true ->
	[]
end.