- 03 Oct, 2011 40 commits
-
-
Naoki Kambe authored
- explicitly shut down the socket of the msgq before shutting down the msgq - do nothing in the shutdown method of MockMsgq for avoiding shutting down the msgq twice - replace the stop method in the shutdown method of the MyStatsHttpd with the shutdown command of stats_httpd
-
Naoki Kambe authored
- move up an assignment of the BIND10_MSGQ_SOCKET_FILE environment variable (BaseModules uses a constant file name during each testcase) - BaseModules checks whether msgq is ready after it started the msgq object. A SessionTimeout is raised here if not.
-
Naoki Kambe authored
-
Naoki Kambe authored
- The function get_availaddr uses socket.getaddrinfo for getting the address family. - The function is_ipv6_enabled uses 3 random ports for checking whether IPv6 is enabled.
-
Naoki Kambe authored
then send the command 'shutdown', and also check each value returned by each invoked command
-
Naoki Kambe authored
b10-stats_test.py - The stats httpd doesn't need to return an argument when it's shutting down. - The testcase sends the 'status' command or the 'shutdown' command to the stats or the stats httpd when they started, and then their returned values are checked.
-
Naoki Kambe authored
- add 3-time retry to creating the server object when it fails in the ThreadingServerManager class - suppress outputs by Msgq, and add dummy sys module and the output methods - pass Exceptions raised while it's running with a thread
-
Naoki Kambe authored
-
Naoki Kambe authored
- remove a logging name from unittest - do stats_httpd.stop() in teadDown() instead of each test case - send 'shutdown' command to kill stats_httpd when testing address already in use
-
Naoki Kambe authored
-
Naoki Kambe authored
buildbot. (unittest.main() with verbosity option is not supported in Python3.1.)
-
Naoki Kambe authored
test_utils.py - more strictly close the io object whether it's successfully opened or not - add verbosity=2 in unittest.main for debugging the failure in the buildbot - don't redict sys.stderr in MockMsgq - rename the function name to create_specfile - switch the verbose in Msgq into True
-
Naoki Kambe authored
get_spec_defaults and add more tests into test_get_spec_defaults
-
Naoki Kambe authored
-
Naoki Kambe authored
-
Naoki Kambe authored
-
Naoki Kambe authored
- A hostname (canonical name of host) is not acceptable in listen_on configuration. - A default port number(starting number for search) is added in args of the function get_availaddr.
-
Naoki Kambe authored
-
Naoki Kambe authored
-
Naoki Kambe authored
- don't use time.sleep for waiting threads are starting or finishing - correct shutting down of mock modules - use _started (threading.Event) where command_handler is invoked - add implementation to changing contents of specfile of MyStatsHttpd - set "BIND10_MSGQ_SOCKET_FILE" only when it's not set yet
-
Naoki Kambe authored
- add function get_availaddr to get available address and port on the platform - add function is_ipv6enabled to check ipv6 enabled on the platform - add miscellaneous changes to refactor unittest
-
Naoki Kambe authored
- don't use DEFAULT_CONFIG - move up mccs.start and open_httpd to __init__(). It takes time to do these functions, and an extra sleep is needed in unittests. - set running to False in http stopping - use validate_config in module_spec class - don't close/open http before it's opened
-
Naoki Kambe authored
- revise header comments in each test script - replace some hard-coded time strings with the constants defined in the setUp function - merged several checks about B10_FROM_SOURCE into the TestOSEnv class
-
Naoki Kambe authored
test_utils.py - change address for test to 127.0.0.1 due to platform 127.0.0.2 can't be assigned - remove unnecessary thread.Event.wait() - add thread.Event.clear() after thread.Event.wait()
-
Naoki Kambe authored
- remove time.sleep from various unittests and add in the "run" method in ThreadingServerManager - adjust the sleep time (TIMEOUT_SEC) - join some small unittests (test_start_with_err, test_command_status, test_command_shutdown)
-
Naoki Kambe authored
headers
-
Naoki Kambe authored
- add more documentations into update_modules, get_statistics_data and update_statistics_data methods - modify two methods: "update_modules" and "get_statistics_data" methods raise StatsError instead of just returning None, when communication between stats module and config manager is failed or when it can't find specified statistics data. - also modify the unittest depending on the changes of these behaviors.
-
Naoki Kambe authored
- set the constant variables in the setUp method in the TestUtilties class, and compare values returned from the functions with these constants in testing methods. - remove the tearDown method which has no test case in the TestCallback class
-
Naoki Kambe authored
-
Naoki Kambe authored
-
Naoki Kambe authored
- rename the name of 'parse_spec' to 'get_spec_defaults' in the result of consideration of what it is doing - modify the description of the function as docstring - fix unitttests for the stats module depending on the function name
-
Naoki Kambe authored
-
Naoki Kambe authored
remove unused messages from the message file add test logging names into unittest scripts
-
Naoki Kambe authored
statistics category in the spec file of a module which has no statistics data.
-
Naoki Kambe authored
- correct error messages in bindctl it prints together with arguments. - modify the command_show function it reports statistics data of the module even if name is not specified. - add/modify unittests depending on the changes of error messages
-
Naoki Kambe authored
-
Naoki Kambe authored
non-existent item name is sent
-
Naoki Kambe authored
is not specified in the argument
-
Naoki Kambe authored
-
Naoki Kambe authored
specfile are changed.
-