validate
上传用户:rrhhcc
上传日期:2015-12-11
资源大小:54129k
文件大小:1k
源码类别:

通讯编程

开发平台:

Visual C++

  1. #!/bin/sh
  2. #
  3. # validate -- run all the test scripts
  4. #
  5. # Copyright (c) 1997 University of Southern California.
  6. # All rights reserved.                                            
  7. #                                                                
  8. # Redistribution and use in source and binary forms are permitted
  9. # provided that the above copyright notice and this paragraph are
  10. # duplicated in all such forms and that any documentation, advertising
  11. # materials, and other materials related to such distribution and use
  12. # acknowledge that the software was developed by the University of
  13. # Southern California, Information Sciences Institute.  The name of the
  14. # University may not be used to endorse or promote products derived from
  15. # this software without specific prior written permission.
  16. # THIS SOFTWARE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR IMPLIED
  17. # WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
  18. # MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
  19. #
  20. try () {
  21. echo "*** $1"
  22.   $1 || {
  23. any_failed=true
  24. failed_list="$failed_list $1"
  25. }
  26. return $?
  27. }
  28. any_failed=false
  29. failed_list=""
  30. cd tcl/test
  31. for i in ptp lan wireless dynamic
  32. do
  33.   try ./test-all-$i
  34. done
  35. if  $any_failed
  36. then
  37. echo "validate overall report: some tests failed:"
  38. echo "$failed_list"
  39. echo "to re-run a specific: cd tcl/test; ./test-all-TEST-NAME"
  40. exit 1
  41. else
  42. echo "validate overall report: all tests passed" 
  43. exit 0
  44. fi