Tag for 2.0.0 final release git-svn-id: svn://svn.open-ils.org/OpenSRF/tags/rel_2_0_0@2242 9efc2488-bf62-4759-914b-345cdb29e865
Add a C unit testing framework and tests for OpenSRF The unit testing framework is "Check" - http://check.sourceforge.net/ These tests can be executed by running 'make check' after you configure and compile the OpenSRF code. To run them, you must have the 'check' package installed. Author: Kevin Beswick <kevinbeswick00@gmail.com> Signed-off-by: Dan Scott <dan@coffeecode.net> Signed-off-by: Kevin Beswick <kevinbeswick00@gmail.com> git-svn-id: svn://svn.open-ils.org/OpenSRF/branches/rel_2_0@2240 9efc2488-bf62-4759-914b-345cdb29e865
Patch from Kevin Beswick to support set operations on certain opensrf message fields. note, this does not currently affect behavior, since values for messages are initially set from parsing JSON without using the access/mutators for setting values. git-svn-id: svn://svn.open-ils.org/OpenSRF/branches/rel_2_0@2235 9efc2488-bf62-4759-914b-345cdb29e865
Sidestep JSON object ordering in unit tests Depending on the JS engine and version of Dojo, the order of attributes in JSON objects may change (as is explicitly allowed by the JSON spec). To avoid false test failures, only use one attribute in the object. git-svn-id: svn://svn.open-ils.org/OpenSRF/branches/rel_2_0@2233 9efc2488-bf62-4759-914b-345cdb29e865
Handle the common NXDOMAIN problem with Python a bit more gracefully Rather than dumping a nasty full stacktrace to the command line, we print a hopefully helpful pointer to the actual problem in plain English. Also, rather than stopping everything if a "stop_all" command was issued, skip the error status in osrf_ctl.sh for the Python bit and carry on shutting down the other services. A bit more convenient if you want to have Python enabled but don't necessarily need it running. git-svn-id: svn://svn.open-ils.org/OpenSRF/branches/rel_2_0@2227 9efc2488-bf62-4759-914b-345cdb29e865
Make javascript unit tests more granular to ease tracking down errors Noticed a failure when running with Rhino 1.7RC2 that wasn't happening with version of Rhino packaged in shrinksafe.jar, and it was a bit tedious narrowing down which test was actually failing. Breaking up the tests into smaller sets will make this process easier and might invite the submission of other tests to target areas that are not yet covered. git-svn-id: svn://svn.open-ils.org/OpenSRF/branches/rel_2_0@2225 9efc2488-bf62-4759-914b-345cdb29e865
Add DOH-based unit test harness for OpenSRF JavaScript The Dojo Objective Harness enables us to run unit tests from the command line or within a browser. Running tests from a command line makes it easier to fold into the continuous integration server. Included in this commit is a small README for setting up command-line testing and a sample set of unit tests that exercise parts of JSON_v1.js. git-svn-id: svn://svn.open-ils.org/OpenSRF/branches/rel_2_0@2223 9efc2488-bf62-4759-914b-345cdb29e865
Give Python services introspection methods matching C and Perl Perl and C services offer "opensrf.system.method" and "opensrf.system.method.all" methods for accessing service information. Renaming Python's methods to match at least enables srfsh to access this information, even if it does still need to be taught to provide that information in a consistent manner. git-svn-id: svn://svn.open-ils.org/OpenSRF/branches/rel_2_0@2221 9efc2488-bf62-4759-914b-345cdb29e865
Improved PID file handling in osrf_ctl.sh Joseph Lewis <joehms22@gmail.com> submitted a patch to address https://bugs.launchpad.net/evergreen/+bug/741088 ("osrf_ctl.sh Doesn't check if process is actually running") As of this patch, when start_perl, start_c, or start_python are started and existing PID files are found for those processes, instead of assuming that the processes are actually running, osrf-ctl.sh now has the intelligence to check the process list to see if there is a matching process. If no running process is found, then the old PID file is removed and the start command is issued. Two additional actions have been added, "smart_clear" and "clear_pid". "smart_clear" checks the PID files against the running processes and removes PID files where no running process is found. This is effectively invoked under the covers when start_* is invoked and a PID file is found. "clear_pid" deletes all PID files without checking to see if there are any running processes. In most cases, it should only be invoked as part of an automated boot sequence. Developer's Certificate of Origin 1.1 By making a contribution to this project, I certify that: (a) The contribution was created in whole or in part by me and I have the right to submit it under the open source license indicated in the file; or (b) The contribution is based upon previous work that, to the best of my knowledge, is covered under an appropriate open source license and I have the right under that license to submit that work with modifications, whether created in whole or in part by me, under the same open source license (unless I am permitted to submit under a different license), as indicated in the file; or (c) The contribution was provided directly to me by some other person who certified (a), (b) or (c) and I have not modified it. (d) I understand and agree that this project and the contribution are public and that a record of the contribution (including all personal information I submit with it, including my sign-off) is maintained indefinitely and may be redistributed consistent with this project or the open source license(s) involved. Signed-off-by: Joseph Lewis <joehms22@gmail.com> git-svn-id: svn://svn.open-ils.org/OpenSRF/branches/rel_2_0@2216 9efc2488-bf62-4759-914b-345cdb29e865
Run OpenSRF JavaScript through jslint for a light cleanup Mostly just semicolons, and shifting a bit of code around to reduce usage of functions/classes before they've been defined. Staying away from the === / !== operators for null/undefined/0/''/true/false for now. git-svn-id: svn://svn.open-ils.org/OpenSRF/branches/rel_2_0@2210 9efc2488-bf62-4759-914b-345cdb29e865