waldenner / robotframework

Automatically exported from code.google.com/p/robotframework
Apache License 2.0
0 stars 0 forks source link

Loading tests and resources from archives (zip, egg, jar) #498

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Use case:
I want to use a resource file that I don't want to copy into the test
source tree as it is maintained and managed in another source repository,
another project.

Possible solution:
I could load it from a supplied zip file and add a library entry that
resolves into a zip file like Java's JarURL:
./lib/myResources.zip/!commons.html

Original issue reported on code.google.com by kai.hack...@gmail.com on 11 Mar 2010 at 11:08

GoogleCodeExporter commented 9 years ago
This is a good idea. In addition to zips also jars (technically the same thing)
should be supported, and in addition to resource files also variables files 
should
supported.

An alternative solution to the JarURL syntax is searching resources from 
zips/jars in
PYTHONPATH/CLASSPATH. We already search resources (and variable files) from
directories in PYTHONPATH and extending that support would be logical.

The core development team doesn't unfortunately have resources to take this 
feature
into RF 2.5 scope (we probably need to descope features already). If external 
helps
is available, getting this into RF 2.5 is nevertheless possible.

Original comment by pekka.klarck on 12 Mar 2010 at 1:02

GoogleCodeExporter commented 9 years ago
It's a interesting idea, It's more useful extending that's loading test case 
from a zip file. 

If there are thousands of test case in a repository, and use the --suite 
parameter or Tags to filter a few of test case to run. all of test case in 
repository will scanning, that's wasted many of time, especially the test cases 
are HTML format. other pain thing is moving or copying the thousands of small 
test case file.

Original comment by Deo...@gmail.com on 1 Oct 2010 at 12:47

GoogleCodeExporter commented 9 years ago
Possibility to run `pybot tests.zip` would be handy. It would definitely ease 
moving tests to different environments for execution. I don't think that would 
help performance, though, as all the files need to be processed in addition to 
opening the archive. Opening zips in Python is pretty trivial so this shouldn't 
be too complicated to implement.

Original comment by pekka.klarck on 1 Oct 2010 at 8:20

GoogleCodeExporter commented 9 years ago
Our html file is parsed by robot and created full text index. If Robot support 
run zip file, It's easy to filter test cases by TAG or long name to archived as 
execution plan. then It need not to parse thousands of test case every time. It 
can improve the loading performance.

That's other benefit, the test case is pre-processed before really running, It 
can fix some parsing error or syntax warning. We can replaced the deprecated 
keywords in exporting test case to archive file.

In my opinion, the robot support loading test case from ZIP, It can drive some 
other useful practice to improve testing process.

Original comment by Deo...@gmail.com on 13 Oct 2010 at 2:36

GoogleCodeExporter commented 9 years ago
Issue 994 has been merged into this issue.

Original comment by robotframework@gmail.com on 2 Dec 2011 at 9:30

GoogleCodeExporter commented 9 years ago

Original comment by robotframework@gmail.com on 2 Dec 2011 at 9:31

GoogleCodeExporter commented 9 years ago
Hi,
Could you please guide on how to fix the problem that am facing.

Scenario:
A spring xml is part of the jar file which I am using in test case. Spring xml 
is loaded while executing the robotKeyword

Error:
Getting IOException: BeanDefinitionStoreException: IOException parsing XML 
document from class path resource, xml cannot be opened as it does not exist.

Any help appreciated.

Cheers

Original comment by pgrao...@gmail.com on 13 Sep 2012 at 11:20

GoogleCodeExporter commented 9 years ago
Robot Framework is being migrated to GitHub and issues have already been moved 
to https://github.com/robotframework/robotframework/issues/. Old IDs are 
preserved so you can find this particular issue using URL like:

    https://github.com/robotframework/robotframework/issues/<id>

Original comment by pekka.klarck on 30 Jun 2014 at 2:12