aboutsummaryrefslogtreecommitdiffstats
path: root/lib/test_server/src/test_server_sup.erl
AgeCommit message (Collapse)Author
2016-02-17Remove test_server as a standalone applicationBjörn Gustavsson
The test_server application has previously been deprecated. In OTP 19, we will move relevant parts of test_server into the common_test application. Test suites that include test_server.hrl must be updated to include ct.hrl instead. Test suites that include test_server_line.hrl must removed that inclusion. Test suites that call the test_server module directly will continue to work in OTP 19. The test suites for Erlang/OTP are built and executed in exactly the same way as previously. Here are some more details. The modules test_server*.erl and erl2html2.erl in lib/test_server/src have been moved to common_test/src. The test_server.hrl and test_server_line.hrl include files have been deleted. The macros in test_server.hrl have been copied into lib/common_test/include/ct.hrl. The ts*.erl modules and their associated data files in lib/test_server/src has been been moved to the new directory lib/common_test/test_server. The ts* modules are no longer built to lib/common_test/ebin. They will only built when 'make release_tests' is executed. The test suite for test_server has been moved to lib/common_test/test. The rest of the files have been deleted.
2015-06-18Change license text to APLv2Bruce Yinhe
2015-05-06Merge branch 'maint'Zandra Hird
Conflicts: OTP_VERSION erts/vsn.mk lib/test_server/src/erl2html2.erl
2015-05-04Fix problem with line number not always showing in logPeter Andersson
OTP-12697
2015-03-20test_server: Replace usage of erlang:now() with usage of new APIDan Gudmundsson
2014-03-20test_server: Fix a Dialyzer warningHans Bolinder
2014-02-24Introduce appup test utilityTobias Schlager
This adds a test function similar to the app file test function existing in test_server. The code is mostly taken from the asn1, snmp and inets test suites. Low-level upgrade instruction checking is stripped. Library application's appup files get specialized treatment, since their content is almost static.
2014-02-13Fix problem with parallel test cases getting identical log file namesPeter Andersson
2013-02-04[test_server] Don't write unicode strings to latin1 log filesSiri Hansen
The unicode update of test_server for R16A introduced a few potential errors when logging to files. Sometimes ~tp or ~ts was used for formatting also when writing to files that were not opened with the {encoding,utf8} option. If then the argument contained unicode characters above 255, the file descriptor would crash. This has been corrected by the following modifications: * Since the 'unexpected_io' log file is used only when the test case HTML file is not available (e.g. between test cases), this file is now also a HTML file and as other test_server HTML logs it is always UTF-8 encoded * Since it is possible to change which information is going to which log file (with test_server_ctrl:set_levels/3), we do not have full control over which information is written to which file. This means that any printout could be written to the 'major' log file (suite.log), which was earlier encoded as latin1. To avoid crashing this file descriptor due to unicode strings, the 'major' log file is now also encoded in UTF-8 (possible incopatibility). * The cross_cover.info file is no longer a text file which can be read with file:consult/1, instead it is written as a pure binary file using term_to_binary when writing and binary_to_term when reading. * The encoding of the file named 'last_name', which only content is the path to the last run.<timestamp> directory, is now dependent on the file name mode of the VM. If file names are expected to be unicode, then the 'last_name' file is UTF-8 encoded, else it is latin1 encoded. Also, ~tp is changed back to ~p unless it is somehow likely that the argument includes strings. It is not obvious that this is the correct thing to do, but some decission had to be taken...
2013-01-25[test_server] Update test_server to handle unicodeSiri Hansen
* Use UTF-8 encoding for all HTML files, except the HTML version of the test suite generated with erl2html2:convert, which will have the same encoding as the original test suite (.erl) file. * Encode link targets in HTML files, allowing both special characters like "/", "&", "?" etc, and latin1 or unicode characters. * Use unicode modifier 't' with ~s and ~p when appropriate. * Use unicode:characters_to_list and unicode:characters_to_binary for conversion between binaries and strings instead of binary_to_list and list_to_binary.
2013-01-09test_server: Remove support for packagesBjörn Gustavsson
2012-11-19[test_server] Fix erl2html2.erl to handle badly indented filesSiri Hansen
Line numbering of erlang files that were not correctly indented could be wrong after coverting to html with erl2html2:convert/[2,3]. This has been corrected. This commit also fixes the following: * There are now link targets for each line and not only for each 10th line - meaning that links from test logs are now to the exact line, and not to the last number for which N rem 10 == 0. * there will only be one link target per function, i.e. the faulty link targets for function clauses are removed. * link targets for function now includes the arity (e.g. func/1 has a link target "func-1") And some tests are added.
2012-11-07[test_server] Add Config to run_test_case_msgloop/1 from the startSiri Hansen
Earlier, #st.config was set to undefined when entering this loop. Then it was updated when the test case itself started. This means that if the test case process crashed during test case initiation, the parent process would not know the Config. This commit saves the initial Config value in the parent process (run_test_case_msgloop/1) from the start.
2012-10-26Simplify managment of test_server_locBjörn Gustavsson
Before line numbers were included in exceptions (in R15), there were parse transforms and macros that would keep the test_server_loc process dictionary variable updated; therefore there is a mod_loc/1 function that will normalize the representation of locations. Simplify the code as following: * 'test_server_loc' should always contain a list with one or more tuples. ({M,F} or {M,F,Line}) * At the beginning of each test case, set 'test_server_loc' to [{Module,Func}] of the the currently executing test case. * Stop updating 'test_server_loc', except when an exception occurs. (It used to be updated when running 'init_per_testcase' and so on.) * Remove the mod_loc/1 function.
2012-10-26Keep the information about the current test case consistentBjörn Gustavsson
Three pieces of information could be out of sync in testcase supervisor process at the time when a timetrap occurred: * test_server_loc (process dictionary) - may indicate that a framework function is executing * test_server_init_or_end_conf (process dictionary) - indicates whether init_per_testcase or end_per_testcase is executing * The current configuration (#st.config) - set using a synchronous call There could be in a crash in spawn_fw_call/7 because the current configuration was not defined when it was expected to. To avoid the problem, introduce set_tc_state/2 (and a corresponding message) to allow setting both an indication what the testcase is executing (e.g. init_per_testcase, framework call, and so on), and the current configuration. Use only that information to handle a timetrap timeout (and aborted testcase and the other reasons for the testcase process to terminate). Completely remove test_server_init_or_end_conf.
2012-09-26Fix obsolete assumption for the return type of os:type/0Björn Gustavsson
os:type/0 could (a long, long time ago) return atoms such as 'vxworks' instead of a two-tuple.
2012-03-30Update copyright yearsBjörn-Egil Dahlberg
2012-03-22Fix various problems with the user timetrap implementationPeter Andersson
2012-03-21Implement support for user controlled timetrapsPeter Andersson
OTP-9988
2011-10-04Merge branch 'dev' into majorLukas Larsson
* dev: (38 commits) Update documentation Rid ct_telnet of doc build warnings Create temporary fix for problem with parallel test cases Update primary bootstrap Correct "Missing Suites" link Add documentation on timetraps and start flags Add missing tests for timetrap handling and fix remaining errors Solve problem with ct_init/end_per_group being counted as test cases Fix errors in test suites Fix invalid call to undefined function Fix problem with test_server_ctrl creating invalid conf test Improve info in CT framework log Update vsn.mk for common_test and test_server Enhance logging performance Change order of include files Add link to last executed test suite on index page Fix problem with location value when init config func calls help func Fix crash when CTHook init fails Correct error in test suite Fix error with incorrect notification after end_per_testcase craches ... Conflicts: bootstrap/bin/start.boot bootstrap/bin/start_clean.boot bootstrap/lib/compiler/ebin/beam_asm.beam bootstrap/lib/compiler/ebin/beam_disasm.beam bootstrap/lib/compiler/ebin/compile.beam bootstrap/lib/compiler/ebin/sys_pre_expand.beam bootstrap/lib/kernel/ebin/code.beam bootstrap/lib/kernel/ebin/code_server.beam bootstrap/lib/kernel/ebin/hipe_unified_loader.beam bootstrap/lib/kernel/ebin/inet.beam bootstrap/lib/kernel/ebin/inet_config.beam bootstrap/lib/kernel/ebin/inet_dns.beam bootstrap/lib/stdlib/ebin/beam_lib.beam bootstrap/lib/stdlib/ebin/dets.beam bootstrap/lib/stdlib/ebin/erl_compile.beam bootstrap/lib/stdlib/ebin/erl_internal.beam bootstrap/lib/stdlib/ebin/erl_scan.beam bootstrap/lib/stdlib/ebin/erl_tar.beam bootstrap/lib/stdlib/ebin/io_lib_fread.beam bootstrap/lib/stdlib/ebin/otp_internal.beam bootstrap/lib/stdlib/ebin/sofs.beam bootstrap/lib/stdlib/ebin/supervisor.beam bootstrap/lib/stdlib/ebin/zip.beam lib/common_test/src/ct.erl lib/common_test/src/ct_run.erl lib/common_test/test/ct_error_SUITE.erl lib/common_test/test/ct_repeat_1_SUITE.erl lib/common_test/test/ct_skip_SUITE.erl lib/test_server/src/test_server.erl
2011-09-23Fix problem with incorrect src linksPeter Andersson
OTP-9396
2011-09-23Fix incorrect module name arg to FW:end_tc/3Peter Andersson
OTP-9379
2011-08-18common_test: Use line numbers in exceptionsBjörn Gustavsson
Remove the old kludgy parse transformations and line numbers macros in common_test and test_server, and use the line numbers in exceptions instead.
2011-04-28Fix problems with timetrap handling in common_test:Peter Andersson
1. ct:timetrap(infinity) not supported. 2. Previous set timetrap for a test case is not cancelled by new one.
2011-03-11Update copyright yearsBjörn-Egil Dahlberg
2011-02-16Update TEST_SERVER_FRAMEWORK os variable to be regarded as undet if set to ↵Lukas Larsson
undefined
2010-06-09Fix so that ct_run converts relative diretories in the code path to absolutePeter Andersson
Directories added with run_test -pa or -pz in the pre erl_args part of the command line will be converted from relative to absolute, this to avoid confusion when Common Test switches working directory during the test run. Also fixed in this commit: Problem with timeouts during init_tc or end_tc (in the Test Server framework).
2010-06-09Implement support for user controllable timetrap parameters (multiply and scale)Peter Andersson
Documentation still missing.
2010-02-17OTP-8311: Various updates and fixes in Common Test and Test ServerPeter Andersson
2009-11-20The R13B03 release.OTP_R13B03Erlang/OTP