aspose file tools*
The moose likes Testing and the fly likes API testing using Groovy Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Engineering » Testing
Bookmark "API testing using Groovy" Watch "API testing using Groovy" New topic
Author

API testing using Groovy

Shraddha Pandya
Greenhorn

Joined: Sep 20, 2004
Posts: 17
Hi

I want to test various APIs available to me in an application jar file using groovy. Since I have jar, I can have source code but wish to pursue only black box testing, in such a way that knowledge of API names and functionality would be sufficient. But as soon as I try to write a class extending TestSuite, it asks for the class name which I want to test (The way JUnit does).
As described above I dont wish to do unit testing of 1 class.

How to proceed forward?

P.S.: Might be a stupid question, my knowledge of groovy is only 1.5 days old.


SCBCD(EJB2.0)
SCJP(1.4)
Shraddha Pandya
Greenhorn

Joined: Sep 20, 2004
Posts: 17
Sorry forgot to mention Eclipse. I was trying to write groovy class extending in TestSuite in Eclipse..
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

How could you test an API without knowing the classes it uses?! What would you call methods on?
Jeanne Boyarsky
internet detective
Marshal

Joined: May 26, 2003
Posts: 29233
    
139

Shraddha Pandya wrote: But as soon as I try to write a class extending TestSuite, it asks for the class name which I want to test (The way JUnit does).

You don't have to though. You can create a TestCase that tests multiple classes or anything really. If the IDE asks for a class name, that's just an assist. Not a requirement of the test.


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: API testing using Groovy
 
Similar Threads
What do you think of Ruby/Rails?
Unit Testing with Groovy?
Grails: A Quick Start Guide Question
Still fuzzy on the Expando class - have any good examples of its use?
Groovy Starting