Reputation: 283
At work I need to run a Java applet every 20-30 min to re-connect to one of the internal applications.
I would like to automate the login in the website of this application and then run this Java applet that does not require any input at all, just accept it so I can just run the script every time the application logs me off.
Is there any way I can do this from Python using urllib
or a similar library?
I know how to do the login part, but I don't know what to do the 'accept and run this applet' part.
Upvotes: 6
Views: 2594
Reputation: 236034
A web application testing framework would be useful for what you ask, it allows you to simulate the interactions of an user (POST, GET, login, clicks, etc.) with a web site.
The tricky part of your question, is interacting with a Java applet - not many webapp testing frameworks will allow you to do that; in particular I don't know a Python framework that offers that functionality, but in my experience, I found that HTTPUnit worked well with applets. Of course, it's in Java and not in Python, but it's worth checking out.
Upvotes: 1