2010-12-13 87 views
1

我想創建一個腳本日誌到wordpress的管理部分,然後檢查更新WordPress的,我已經在使用這裏提到的例子做了這個爲Drupal這裏評論http://drupal.org/node/147413#comment-1269222日誌與webinject

但是我堅持postbody的一部分,它不會登錄管理頁面。

有什麼想法?

+0

嗯,我無法得到這個工作,但有人做了一個nagios檢查工程 – hoberion 2010-12-22 09:46:47

回答

0

我可以告訴你我們爲Atlassian的套件創建測試用例,也許例子可以幫助你,這種情況是我們爲CONFLUENCE

TESTDATA文件

confluence_Basic_AD_Login_testdata.xml創建的(它第一次登錄到web應用,然後通過檢查儀表盤檢查登錄)

<testcases repeat="1"> 

<case 
     id="1" 
     description="Get Confluence Login Page" 
     method="post" 
     url="https://confluence.company.com/login.action" 
     postbody="os_username=conflumin&os_password=conflumin123" 
     errormessage="Unable to connect to the login page of Confluence" 
     verifypositive="Username" 
     logrequest="yes" 
     logresponse="yes" 
/> 

<case 
     id="2" 
     description="Authentication by AD to Confluence" 
     url="https://confluence.company.com/dashboard.action" 
     verifypositive="Dashboard" 
     errormessage="Unable to authenticate user in Confluence" 
     logrequest="yes" 
     logresponse="yes" 

/> 

</testcases> 

CONFIG FILE

文件:confluence_Basic_AD_Login_config.xml

<testcasefile>confluence_Basic_AD_Login_testdata.xml</testcasefile> 
    <useragent>WebInject Application Tester</useragent> 
    <timeout>10</timeout> 
    <globaltimeout>30</globaltimeout> 
    <reporttype>nagios</reporttype> 

這一切,並檢查工作與NagiosXI。 希望它可以幫助你。

karina