logintest_pos.sh 314 B

123456789101112131415161718
  1. #!/bin/bash
  2. SCRIPT_PATH=${0%/*}
  3. if [ "$0" != "$SCRIPT_PATH" ] && [ "$SCRIPT_PATH" != "" ]; then
  4. cd "$SCRIPT_PATH/.."
  5. fi
  6. bin/ccats-cli --batch test/logintest_pos.txt
  7. if [ ! -f test/logintest_pos.txt.out ];
  8. then
  9. exit 1;
  10. fi
  11. if [ -z "$(grep "Login ok." test/logintest_pos.txt.out)" ];
  12. then
  13. exit 1;
  14. fi
  15. exit 0;