Status: New
Owner: ----
Labels: Type-Enhancement Priority-Medium
New issue 1613 by [email protected]: Keyword to move/copy multiple
files using patterns (wildcards) should be added to OperatingSystem library
http://code.google.com/p/robotframework/issues/detail?id=1613
Currently the Move File and Copy File keywords of OperatingSystem library
do not accept any wildcards to make it possible to copy or move multiple
source files on one call. It would be nice to have also possibility to give
a list of files to be copied to avoid using FOR-loops in a test case for
that purpose.
Attached is a suggestion of the implementation (based on the library from
RF2.8.3) and some test cases for testing the implementation and showing how
the keywords work. I tested the implementation in Windows 7 with RF2.8.3
(Python), not in any other environments.
There is still anyhow at least one thing to decide: whether it should fail
the keyword execution when multiple files are moved/copied to same
destination file (i.e. when dest is not a directory but a file and there
are multiple source files), or just warn about that and overwrite the
destination file, like it does now.
The added methods are: copy_files, move_files, _normalize_dest and
_prepare_list_of_source_files
Method _normalize_source_and_dest was modified to call _normalize_dest
where part of the earlier content of that method was moved to.
Attachments:
OperatingSystem.py 59.6 KB
test copy files.txt 6.8 KB
test move files.txt 12.6 KB
--
You received this message because this project is configured to send all
issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings
--
---
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 [email protected].
For more options, visit https://groups.google.com/groups/opt_out.