From: Dave D. <d.j...@hu...> - 2002-03-22 10:14:26
|
Dear All, I have searched the archives and posted on the Junit list. No definitive answer, so trying again. ;) I have been using unittest with Jython but would like to use JUnit for teaching/illustrative purposes. The maillings suggest that use of JUnit and automatic suite generation is problematical due to reflection. I have tried using docstrings and jythonc but without much success. Does there exist a port of the JUnit distribution demo ( Money ) in jython that successfully works with GUI runner that I can use as a leg-up ? Many thanks David ________________________________________________________________________________ ******************************************************** * David Dench * * School of Computing & Mathematics * * The University of Huddersfield * * Tel: 01484 472083 * * email: d.j...@hu... * * web: http://scom.hud.ac.uk/scomdjd * ******************************************************** ________________________________________________________________________________ |
From: Stephen N. <ste...@co...> - 2002-03-22 15:29:26
|
I have a system made up of two parts. One in Jython and the other in CPython. The reason for this is that I could not find a Gnutella library in CPython, but I could in Java. Also I have been having difficulties with BerkeleyDB Java bindings, so I decided to use CPython's bsddb. Anyway, I would like the jython and python processes to communicate with each other. I was think of IPC using scokets, but I'm not sure if this is the best option. I'd be grateful for any advice on this as I have not done this sort of thing before. Alternatively if anyone knows of a good python gnutella library (like Jtella), that would be an alternative solution. Thanks Again. Stephen |
From: Michel P. <mi...@di...> - 2002-03-22 16:13:19
|
> I'd be grateful for any advice on this as I have not done this sort of > thing before. Alternatively if anyone knows of a good python gnutella > library (like Jtella), that would be an alternative solution. I have a CPython system (Zope) talking to a Jython system via xml-rpc. xmlrpcserver.py can be found at: http://www.pythonware.com/products/xmlrpc/index.htm it works fine in jython. Note, xml-rpc will only give you simple data pasing, numbers, strings, lists, "structs" etc. -Michel |
From: Kevin B. <kb...@ca...> - 2002-03-22 23:10:03
|
You have several options, ranging in rough order of difficulty: - Python-specific RPC technology (PYRO http://pyro.sourceforge.net/ or DOPY http://www.users.cloud9.net/~proteus/dopy/) I actually haven't used either, as I've needed cross language interoperability, but I probably would use one of them if I were doing all-Python RPC - Python-based CORBA solution (Fnorb or omniorb and possibly Java's CORBA interfaces) - XML-based RPC technology (xmlrpc/soap) (haven't done much with these) - custom sockets (probably using pickles, maybe SimpleTCPServer or BaseHTTPServer) - some other communication mechanism you dream up - write to a file, database, etc. In spite of what RPC vendors would have you think, none of this is very difficult, and unless you have significant stability or performance requirements, all should be quite suitable. I imagine that if PYRO or DOPY works for you, they will be significantly easier than any of the others, but all the others are pretty similar in difficulty. IMO, YMMV, etc. kb Stephen Naicken wrote: >I have a system made up of two parts. One in Jython and the other in >CPython. The reason for this is that I could not find a Gnutella >library in CPython, but I could in Java. Also I have been having >difficulties with BerkeleyDB Java bindings, so I decided to use >CPython's bsddb. > >Anyway, I would like the jython and python processes to communicate with >each other. I was think of IPC using scokets, but I'm not sure if this >is the best option. > >I'd be grateful for any advice on this as I have not done this sort of >thing before. Alternatively if anyone knows of a good python gnutella >library (like Jtella), that would be an alternative solution. > >Thanks Again. > >Stephen > > >_______________________________________________ >Jython-users mailing list >Jyt...@li... >https://lists.sourceforge.net/lists/listinfo/jython-users > |
From: Eric B. <EBi...@sa...> - 2002-03-27 00:44:42
|
I want to generate HTML documentation for my Jython modules ala `pydoc -w` for CPython. Pydoc doesn't work for me because "import java" fails under CPython. The best docstring HTML generator I've yet found for Jython is HappyDoc (http://happydoc.sourceforge.net/). What other alternatives are out there? -- Eric Bieschke |
From: Kevin B. <kb...@ca...> - 2002-03-22 23:29:22
|
One more I forgot to mention, which may be suitable for your application: If you are going to have one of your processes spawn the other, you can just use os.popen* (in CPython) or Java's Runtime.exec (in Jython until I or someone else implements popen* functions) to spawn the child process. The parent then reads from/writes to the returned file handles, and the child reads/writes stdin/stdout. kb Kevin Butler wrote: > You have several options, ranging in rough order of difficulty: > > - Python-specific RPC technology (PYRO http://pyro.sourceforge.net/ or > DOPY http://www.users.cloud9.net/~proteus/dopy/) > I actually haven't used either, as I've needed cross language > interoperability, but I probably would use one of them if I were doing > all-Python RPC > > - Python-based CORBA solution (Fnorb or omniorb and possibly Java's > CORBA interfaces) > > - XML-based RPC technology (xmlrpc/soap) (haven't done much with these) > > - custom sockets (probably using pickles, maybe SimpleTCPServer or > BaseHTTPServer) > > - some other communication mechanism you dream up - write to a file, > database, etc. > > In spite of what RPC vendors would have you think, none of this is > very difficult, and unless you > have significant stability or performance requirements, all should be > quite suitable. I imagine that > if PYRO or DOPY works for you, they will be significantly easier than > any of the others, but all > the others are pretty similar in difficulty. > > IMO, YMMV, etc. > > kb > > Stephen Naicken wrote: > >> I have a system made up of two parts. One in Jython and the other in >> CPython. The reason for this is that I could not find a Gnutella >> library in CPython, but I could in Java. Also I have been having >> difficulties with BerkeleyDB Java bindings, so I decided to use >> CPython's bsddb. >> >> Anyway, I would like the jython and python processes to communicate with >> each other. I was think of IPC using scokets, but I'm not sure if this >> is the best option. >> >> I'd be grateful for any advice on this as I have not done this sort of >> thing before. Alternatively if anyone knows of a good python gnutella >> library (like Jtella), that would be an alternative solution. >> >> Thanks Again. >> >> Stephen >> >> >> _______________________________________________ >> Jython-users mailing list >> Jyt...@li... >> https://lists.sourceforge.net/lists/listinfo/jython-users >> > > > > _______________________________________________ > Jython-users mailing list > Jyt...@li... > https://lists.sourceforge.net/lists/listinfo/jython-users |
From: Oti <oh...@ya...> - 2002-04-04 21:27:27
|
[ Dave Dench ] > Dear All, > I have searched the archives and posted on the Junit list. > No definitive answer, so trying again. ;) > I have been using unittest with Jython but would like to use JUnit > for teaching/illustrative purposes. The maillings suggest that use > of JUnit and automatic suite generation is problematical due to > reflection. > I have tried using docstrings and jythonc but without much success. > Does there exist a port of the JUnit distribution demo ( Money ) in > jython that successfully works with GUI runner that I can use as a > leg-up ? Hello Dave, not sure if this is what you are looking for: We extended JUnit in a way that we can use the normal ui (gui or text) to run our tests, but the tests themselves are written in Jython. One advantage of this is (in addition to all other advantages of Jython versus Java) that we can unit test both Java and Jython classes in the same framework. There was a small change necessary to the getTest() method in the junit.<any>ui.TestRunner classes: If a Jython unit test should be found, use a custom test finder to locate the .py file containing the test. The Jython test class extends junit.framework.TestCase (and therefore implements junit.framework.Test). The trick is to use embedded Jython to be able to return a junit.framework.Test object to the TestRunner. This way we can use the whole junit framework to run Jython unit tests behaving like normal java unit tests. Hopefully this gave you an idea. Best wishes, Oti. __________________________________________________ Do You Yahoo!? Yahoo! Tax Center - online filing with TurboTax http://taxes.yahoo.com/ |
From: Frank C. <fc...@pu...> - 2002-04-05 06:51:07
|
Hi Dave: I manage an open source project called TestMaker (formerly Load) that builds intelligent test agents to assure Web Services (HTTP, HTTPS, SOAP, .NET, etc.) for functionality, scalability and performance. TestMaker embeds Jython as a scripting language to drive a library of test objects. You may find it to be a good compliment to Junit. About your question on learning materials, take a look at: http://www.pushtotest.com/ptt/thekit.html This is a knowledge kit I put together for BEA that shows how to set-up a SOAP-based Web service and test it using TestMaker. The kit comes with an article and all the source code. You're welcome to use it as courseware. -Frank -- Frank Cohen, CEO, PushToTest, www.pushtotest.com, phone: 408 374 7426 Come to PushToTest for free open-source Active Security solutions that test, monitor and automate Web Service systems for functionality, scalability and performance. > From: Dave Dench <d.j...@hu...> > Date: Fri, 22 Mar 2002 10:13:42 GMT > To: jyt...@li... > Subject: [Jython-users] Possibly FAQ re Junit > > Dear All, > I have searched the archives and posted on the Junit list. > No definitive answer, so trying again. ;) > I have been using unittest with Jython but would like to use JUnit > for teaching/illustrative purposes. The maillings suggest that use > of JUnit and automatic suite generation is problematical due to reflection. > I have tried using docstrings and jythonc but without much success. > Does there exist a port of the JUnit distribution demo ( Money ) in > jython that successfully works with GUI runner that I can use as a > leg-up ? > Many thanks > David > > ______________________________________________________________________________ > __ > > ******************************************************** > * David Dench * > * School of Computing & Mathematics * > * The University of Huddersfield * > * Tel: 01484 472083 * > * email: d.j...@hu... * > * web: http://scom.hud.ac.uk/scomdjd * > ******************************************************** > ______________________________________________________________________________ > __ > > _______________________________________________ > Jython-users mailing list > Jyt...@li... > https://lists.sourceforge.net/lists/listinfo/jython-users |