1

I would like to save simpletest test results into a log file. What bash commands should I use ?

I tried this command (example) but nothing is saved into /var/tmp folder :

sudo -u apache drush test-run Comment --xml /var/tmp

I use Linux , Drupal 7.12, Drush 4.5

3 Answers 3

5

I don't use drush test-run, but Drush options are always in the form --xml=/var/tmp.

c.f. http://drupal.org/node/1416198

From drush help test-run

 --xml      Output verbose test results to a     
            specified directory using the JUnit  
            test reporting format. Useful for    
            integrating with Jenkins.  

Try:

sudo -u apache drush test-run Comment --all --xml=/var/tmp
1

Try something like this:

sudo -u apache drush test-run > /var/tmp/whatever.txt
3
  • I tried this as well but unfortunately this also didn't work.
    – LLub
    Commented Feb 10, 2012 at 23:19
  • Actually what I did was just this: drush test-run > /var/tmp/whatever.txt ... What is the error you get?
    – dxvargas
    Commented Feb 11, 2012 at 3:41
  • 1
    if I use your example nothing goes into whatever.txt
    – LLub
    Commented Feb 11, 2012 at 8:29
0

What worked for me finally was:

sudo -u apache drush test-run Comment --xml=/var/tmp >/var/tmp/test.log 2>/var/tmp/test.err

Thanks for help from hiphip and greg_1_anderson :)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.