Generate test report after UI test, upload svn with shell script

Source: Internet
Author: User

A test report is generated after the UI test, and the report is saved in a fixed path

The shell script uploads this report

#!/bin/bash-ile#svn Download File #svn checkout http://svn.xxx.com/svn/xxxx/trunk/ui/report--username xxx--password dsdfsdf;SVN checkout http://Svn.xxx.com.cn/svn/xxxx/trunk/ui/reportCD Reportpwd#是否存在report file, if it exists, delete it, so that SVN will not save a lot of files, save only one file files=$(lsReport*.html2>/dev/NULL|WC-l)if[$files! ="0"] ; Then#存在文件就删除Echo "File exists"SVN Delete report*. HTML SVN commit-M"Delete Report"Else     Echo "file does not exist"fi#获取报告文件存放idflag=`Cat/users/pub_pawf_autotest/autoconf/Flag.txt 'Echo$flag # Path to generate report file Reportpath="/users/pub_pawf_autotest/autoconf/report/report"$flag". html"#生成的报告文件名addReportPath=report"$flag". htmlEcho$reportPath # If the generated report file exists, upload svn to determine if the file existsif[-F $reportPath]; Then     Echo "report File exists"$reportPathCP$reportPath. SVN add $addReportPath svn commit-M"Add Report"$addFilePathElse    Echo "report file does not exist"$reportPathfiCD..RM-RF report# re-download the svn file under Upload report svn checkout http://Svn.xxx.com/svn/xxx/trunk/ui/report

Generate test report after UI test, upload svn with shell script

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.