codeforequity-at / botium-core

The Selenium for Chatbots - Bots Testing Bots
https://www.botium.ai
MIT License
229 stars 64 forks source link

How to export test results while using CLI #276

Closed HossamEmam95 closed 5 years ago

HossamEmam95 commented 5 years ago

I ran tests using cli .. by this command

botium-cli run --config path/to/botium.json --convos path/to/files

the results are shown in the terminal .. how can I export this results in txt file?

codeforequity-at commented 5 years ago

Use the --output switch to select the output format.

'tap', 'json', 'xunit', 'spec', 'list', 'mochawesome'

HossamEmam95 commented 5 years ago

I tried this .. but it just change the format appears in the terminal .. i want to export it in a txt file to save it for later compare

codeforequity-at commented 5 years ago

You can add "> output.txt" to the commandline to redirect the output to a file.

HossamEmam95 commented 5 years ago

I tried this .. but it just change the format appears in the terminal .. i want to export it in a txt file to save it for later compare

codeforequity-at commented 5 years ago

will test myself and maybe provide fix for it

codeforequity-at commented 5 years ago

Tested it and it works:

botium-cli run > out.txt

Will write the test report to out.txt For plain text reports, the TAP-format is maybe the best choice.

botium-cli run tap > out.txt

Output file looks like this:

1..1
ok 1 Botium Test-Suite give me picture
# tests 1
# pass 1
# fail 0