diff options
author | Andrey Pampukha <[email protected]> | 2010-03-15 15:26:02 +0100 |
---|---|---|
committer | Raimo Niskanen <[email protected]> | 2010-06-09 16:19:13 +0200 |
commit | a9c315929d96c7d0d0e5e79f8fc0ba0c7f17e94d (patch) | |
tree | 4aee70a5dfd2f379e6b11b3f61ae920f0b7cdb33 /lib/common_test/src | |
parent | 9ad66edc389b04141443bc5339c9f34dfeac59f0 (diff) | |
download | otp-a9c315929d96c7d0d0e5e79f8fc0ba0c7f17e94d.tar.gz otp-a9c315929d96c7d0d0e5e79f8fc0ba0c7f17e94d.tar.bz2 otp-a9c315929d96c7d0d0e5e79f8fc0ba0c7f17e94d.zip |
Changed return value tags for config file handling
Return value tags modified and various documentation updates made (work in progress).
Diffstat (limited to 'lib/common_test/src')
-rwxr-xr-x | lib/common_test/src/ct_config.erl | 4 | ||||
-rwxr-xr-x | lib/common_test/src/ct_config_plain.erl | 2 | ||||
-rwxr-xr-x | lib/common_test/src/ct_config_xml.erl | 2 | ||||
-rw-r--r-- | lib/common_test/src/ct_run.erl | 10 | ||||
-rw-r--r-- | lib/common_test/src/ct_testspec.erl | 4 |
5 files changed, 11 insertions, 11 deletions
diff --git a/lib/common_test/src/ct_config.erl b/lib/common_test/src/ct_config.erl index 4b99d8db88..5623b80592 100755 --- a/lib/common_test/src/ct_config.erl +++ b/lib/common_test/src/ct_config.erl @@ -685,7 +685,7 @@ check_callback_load(Callback)-> end. check_config_files(Configs)-> - lists:keysearch(nok, 1, + lists:keysearch(error, 1, lists:flatten( lists:map(fun({Callback, Files})-> case check_callback_load(Callback) of @@ -695,7 +695,7 @@ check_config_files(Configs)-> end, Files); {error, _}-> - {nok, {callback, Callback}} + {error, {callback, Callback}} end end, Configs))). diff --git a/lib/common_test/src/ct_config_plain.erl b/lib/common_test/src/ct_config_plain.erl index 327fc66b40..0fed58e45a 100755 --- a/lib/common_test/src/ct_config_plain.erl +++ b/lib/common_test/src/ct_config_plain.erl @@ -71,7 +71,7 @@ check_parameter(File)-> true-> {ok, {file, File}}; false-> - {nok, {nofile, File}} + {error, {nofile, File}} end. read_config_terms(Bin) when is_binary(Bin) -> diff --git a/lib/common_test/src/ct_config_xml.erl b/lib/common_test/src/ct_config_xml.erl index e14bb0f9f9..111d1426c9 100755 --- a/lib/common_test/src/ct_config_xml.erl +++ b/lib/common_test/src/ct_config_xml.erl @@ -42,7 +42,7 @@ check_parameter(File)-> true-> {ok, {file, File}}; false-> - {nok, {nofile, File}} + {error, {nofile, File}} end. % actual reading of the config diff --git a/lib/common_test/src/ct_run.erl b/lib/common_test/src/ct_run.erl index 0e7da60821..92c2334a80 100644 --- a/lib/common_test/src/ct_run.erl +++ b/lib/common_test/src/ct_run.erl @@ -245,11 +245,11 @@ check_and_install_configfiles(Configs, LogDir, EvHandlers) -> false-> install([{config,Configs}, {event_handler,EvHandlers}], LogDir); - {value, {nok, {nofile, File}}} -> + {value, {error, {nofile, File}}} -> {error,{cant_read_config_file,File}}; - {value, {nok, {wrong_config, Message}}}-> + {value, {error, {wrong_config, Message}}}-> {error,{wrong_config, Message}}; - {value, {nok, {callback, File}}} -> + {value, {error, {callback, File}}} -> {error,{cant_load_callback_module,File}} end. @@ -702,9 +702,9 @@ check_config_file(Callback, File)-> ?abs(File); {ok, {config, _}}-> File; - {nok, {wrong_config, Message}}-> + {error, {wrong_config, Message}}-> exit({wrong_config, {Callback, Message}}); - {nok, {nofile, File}}-> + {error, {nofile, File}}-> exit({no_such_file, ?abs(File)}) end. diff --git a/lib/common_test/src/ct_testspec.erl b/lib/common_test/src/ct_testspec.erl index ea30ccc13b..5248a6e319 100644 --- a/lib/common_test/src/ct_testspec.erl +++ b/lib/common_test/src/ct_testspec.erl @@ -321,9 +321,9 @@ get_absfile(Callback, FullName,#testspec{spec_dir=SpecDir}) -> filename:join(Dir,File); {ok, {config, FullName}}-> FullName; - {nok, {nofile, FullName}}-> + {error, {nofile, FullName}}-> FullName; - {nok, {wrong_config, FullName}}-> + {error, {wrong_config, FullName}}-> FullName end. |