2 new revisions:
Revision: 971c3ec566a7
Branch: default
Author: Mika Hänninen <mika.hanni...@gmail.com>
Date: Tue Jun 11 05:07:40 2013
Log: process lib: test refactoring
http://code.google.com/p/robotframework/source/detail?r=971c3ec566a7
Revision: 61cdfd5183b3
Branch: default
Author: Mika Hänninen <mika.hanni...@gmail.com>
Date: Tue Jun 11 05:07:44 2013
Log: Automated merge with https://code.google.com/p/robotframework/
http://code.google.com/p/robotframework/source/detail?r=61cdfd5183b3
==============================================================================
Revision: 971c3ec566a7
Branch: default
Author: Mika Hänninen <mika.hanni...@gmail.com>
Date: Tue Jun 11 05:07:40 2013
Log: process lib: test refactoring
http://code.google.com/p/robotframework/source/detail?r=971c3ec566a7
Modified:
/atest/testdata/standard_libraries/process/process_library.txt
/atest/testdata/standard_libraries/process/terminate_and_pid.txt
=======================================
--- /atest/testdata/standard_libraries/process/process_library.txt Tue Jun
11 04:29:48 2013
+++ /atest/testdata/standard_libraries/process/process_library.txt Tue Jun
11 05:07:40 2013
@@ -46,14 +46,14 @@
${output}= Get File %{TEMPDIR}${/}myfile_1.txt
Should Not Be Empty ${output}
Should Match ${output} ${result.stdout}*
- [Teardown] Remove File %{TEMPDIR}${/}myfile_1.txt
+ [Teardown] Run Keyword And Ignore Error Remove
File %{TEMPDIR}${/}myfile_1.txt
Setting Stderr
${result}= Run Process python -c "1/0" shell=True
stderr=%{TEMPDIR}${/}myfile.txt
${output}= Get File %{TEMPDIR}${/}myfile.txt
Should Not Be Empty ${output}
Should Match ${output} ${result.stderr}*
- [Teardown] Remove File %{TEMPDIR}${/}myfile.txt
+ [Teardown] Run Keyword And Ignore Error Remove
File %{TEMPDIR}${/}myfile.txt
Without Env Configuration the Environment Should Be As It Was
Set Environment Variable normalvar normal
@@ -132,7 +132,7 @@
Should Match ${result.stderr} *ZeroDivisionError*
Should Be Equal ${result.stdout_path} ${path}
Should Be Equal ${result.stderr_path} ${path}
- [Teardown] Remove File ${path}
+ [Teardown] Run Keyword And Ignore Error Remove File ${path}
Current working directory should be used with stdout and stderr
Create Directory %{TEMPDIR}${/}hc
@@ -142,7 +142,7 @@
${output2}= Get File %{TEMPDIR}${/}hc${/}myerr.txt
Should Match ${output} *moon kuu*
Should Match ${output2} *ZeroDivisionError*
- [Teardown] Remove Directory %{TEMPDIR}${/}hc recursive=True
+ [Teardown] Run Keyword And Ignore Error Remove
Directory %{TEMPDIR}${/}hc recursive=True
Current working directory should not be used with stdout and stderr when
absolute path in use
Create Directory %{TEMPDIR}${/}hc
@@ -156,9 +156,7 @@
Should Match ${stderr} *ZeroDivisionError*
Should Be Equal ${result.stdout_path} ${stdout_path}
Should Be Equal ${result.stderr_path} ${stderr_path}
- [Teardown] Run Keywords
- ... Remove Directory %{TEMPDIR}${/}hc recursive=True AND
- ... Remove File ${stdout_path}
+ [Teardown] Remove Directory and File %{TEMPDIR}${/}hc
${stdout_path}}
*** Keywords ***
Restart Suite Process If Needed
@@ -189,3 +187,8 @@
${systemroot}= Get Environment Variable SYSTEMROOT default=.
${setenv}= Create Dictionary PATH ${path} SYSTEMROOT
${SYSTEMROOT} @{env_args}
[Return] ${setenv}
+
+Remove Directory and File
+ [Arguments] ${dir_to_remove} ${file_to_remove}
+ Run Keyword And Ignore Error Remove Directory
${dir_to_remove} recursive=True
+ Run Keyword And Ignore Error Remove File ${file_to_remove}
=======================================
--- /atest/testdata/standard_libraries/process/terminate_and_pid.txt Tue
Jun 11 04:28:34 2013
+++ /atest/testdata/standard_libraries/process/terminate_and_pid.txt Tue
Jun 11 05:07:40 2013
@@ -3,6 +3,7 @@
Library Process.py
Library OperatingSystem
Resource resource.txt
+Test Timeout 15s
*** Test Cases ***
Run process does not change active process
@@ -68,7 +69,7 @@
${stdout}= Normalize Path %{TEMPDIR}${/}stdout.txt
${handle}= Run Process python -c "for i in range(350000):
\tprint 'a'*400" shell=True stdout=${stdout} stderr=STDOUT
File Should Not Be Empty ${stdout}
- [Teardown] Remove File ${stdout}
+ [Teardown] Run Keyword And Ignore Error Remove File ${stdout}
Getting PIDs in different ways should give same result
${handle}= Start Process python -c "print 'hello'"
shell=True alias=hello
==============================================================================
Revision: 61cdfd5183b3
Branch: default
Author: Mika Hänninen <mika.hanni...@gmail.com>
Date: Tue Jun 11 05:07:44 2013
Log: Automated merge with https://code.google.com/p/robotframework/
http://code.google.com/p/robotframework/source/detail?r=61cdfd5183b3
--
---
You received this message because you are subscribed to the Google Groups "robotframework-commit" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to robotframework-commit+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.